| Differences between
and this patch
- a/Source/WebKit2/ChangeLog +20 lines
Lines 1-3 a/Source/WebKit2/ChangeLog_sec1
1
2012-09-05  Alexander Shalamov  <alexander.shalamov@intel.com>
2
3
        [EFL][WK2] Add fullscreen enter / exit signals to the ewk_view API
4
        https://bugs.webkit.org/show_bug.cgi?id=92362
5
6
        Reviewed by NOBODY (OOPS!).
7
8
        Add fullscreen,enter and fullscreen,exit signals to ewk_view API, so that
9
        UI could enter and exit fullscreen mode when requested.
10
11
        * UIProcess/API/efl/ewk_view.cpp:
12
        (ewk_view_base_add):
13
        (ewk_view_full_screen_enter):
14
        (ewk_view_full_screen_exit):
15
        * UIProcess/API/efl/ewk_view.h:
16
        * UIProcess/API/efl/ewk_view_private.h:
17
        * UIProcess/efl/WebFullScreenManagerProxyEfl.cpp:
18
        (WebKit::WebFullScreenManagerProxy::enterFullScreen):
19
        (WebKit::WebFullScreenManagerProxy::exitFullScreen):
20
1
2012-09-04  Allan Sandfeld Jensen  <allan.jensen@nokia.com>
21
2012-09-04  Allan Sandfeld Jensen  <allan.jensen@nokia.com>
2
22
3
        Allow child-frame content in hit-tests.
23
        Allow child-frame content in hit-tests.
- a/Source/WebKit2/UIProcess/API/efl/ewk_view.cpp +33 lines
Lines 35-40 a/Source/WebKit2/UIProcess/API/efl/ewk_view.cpp_sec1
35
#include "WebPageGroup.h"
35
#include "WebPageGroup.h"
36
#include "WebPopupItem.h"
36
#include "WebPopupItem.h"
37
#include "WebPopupMenuProxyEfl.h"
37
#include "WebPopupMenuProxyEfl.h"
38
#include "WebPreferences.h"
38
#include "ewk_back_forward_list_private.h"
39
#include "ewk_back_forward_list_private.h"
39
#include "ewk_context.h"
40
#include "ewk_context.h"
40
#include "ewk_context_private.h"
41
#include "ewk_context_private.h"
Lines 58-63 a/Source/WebKit2/UIProcess/API/efl/ewk_view.cpp_sec2
58
#include <WebKit2/WKPageGroup.h>
59
#include <WebKit2/WKPageGroup.h>
59
#include <wtf/text/CString.h>
60
#include <wtf/text/CString.h>
60
61
62
#if ENABLE(FULLSCREEN_API)
63
#include "WebFullScreenManagerProxy.h"
64
#endif
65
61
#if USE(ACCELERATED_COMPOSITING)
66
#if USE(ACCELERATED_COMPOSITING)
62
#include <Evas_GL.h>
67
#include <Evas_GL.h>
63
#endif
68
#endif
Lines 714-719 static void _ewk_view_initialize(Evas_Object* ewkView, Ewk_Context* context, WKP a/Source/WebKit2/UIProcess/API/efl/ewk_view.cpp_sec3
714
    ewk_view_policy_client_attach(wkPage, ewkView);
719
    ewk_view_policy_client_attach(wkPage, ewkView);
715
    ewk_view_resource_load_client_attach(wkPage, ewkView);
720
    ewk_view_resource_load_client_attach(wkPage, ewkView);
716
    ewk_view_ui_client_attach(wkPage, ewkView);
721
    ewk_view_ui_client_attach(wkPage, ewkView);
722
#if ENABLE(FULLSCREEN_API)
723
    priv->pageProxy->fullScreenManager()->setWebView(ewkView);
724
    priv->pageProxy->pageGroup()->preferences()->setFullScreenEnabled(true);
725
#endif
717
}
726
}
718
727
719
static Evas_Object* _ewk_view_add_with_smart(Evas* canvas, Evas_Smart* smart)
728
static Evas_Object* _ewk_view_add_with_smart(Evas* canvas, Evas_Smart* smart)
Lines 1152-1157 void ewk_view_display(Evas_Object* ewkView, const IntRect& rect) a/Source/WebKit2/UIProcess/API/efl/ewk_view.cpp_sec4
1152
1161
1153
/**
1162
/**
1154
 * @internal
1163
 * @internal
1164
 *
1165
 * Emits signal: "fullscreen,enter".
1166
 */
1167
void ewk_view_full_screen_enter(Evas_Object* ewkView)
1168
{
1169
#if ENABLE(FULLSCREEN_API)
1170
    evas_object_smart_callback_call(ewkView, "fullscreen,enter", 0);
1171
#endif
1172
}
1173
1174
/**
1175
 * @internal
1176
 *
1177
 * Emits signal: "fullscreen,exit".
1178
 */
1179
void ewk_view_full_screen_exit(Evas_Object* ewkView)
1180
{
1181
#if ENABLE(FULLSCREEN_API)
1182
    evas_object_smart_callback_call(ewkView, "fullscreen,exit", 0);
1183
#endif
1184
}
1185
1186
/**
1187
 * @internal
1155
 * A download for that view was cancelled.
1188
 * A download for that view was cancelled.
1156
 *
1189
 *
1157
 * Emits signal: "download,cancelled" with pointer to a Ewk_Download_Job.
1190
 * Emits signal: "download,cancelled" with pointer to a Ewk_Download_Job.
- a/Source/WebKit2/UIProcess/API/efl/ewk_view.h +2 lines
Lines 42-47 a/Source/WebKit2/UIProcess/API/efl/ewk_view.h_sec1
42
 *   when done to continue with the form submission. If the last reference is removed on a
42
 *   when done to continue with the form submission. If the last reference is removed on a
43
 *   #Ewk_Form_Submission_Request and the form has not been submitted yet,
43
 *   #Ewk_Form_Submission_Request and the form has not been submitted yet,
44
 *   ewk_form_submission_request_submit() will be called automatically.
44
 *   ewk_form_submission_request_submit() will be called automatically.
45
 * - "fullscreen,enter", emitted when view is requested to enter full screen mode.
46
 * - "fullscreen,exit", emitted when view is requested to exit full screen mode.
45
 * - "intent,request,new", Ewk_Intent*: reports new Web intent request.
47
 * - "intent,request,new", Ewk_Intent*: reports new Web intent request.
46
 * - "intent,service,register", Ewk_Intent_Service*: reports new Web intent service registration.
48
 * - "intent,service,register", Ewk_Intent_Service*: reports new Web intent service registration.
47
 * - "load,error", const Ewk_Web_Error*: reports main frame load failed.
49
 * - "load,error", const Ewk_Web_Error*: reports main frame load failed.
- a/Source/WebKit2/UIProcess/API/efl/ewk_view_private.h +4 lines
Lines 59-64 void ewk_view_download_job_failed(Evas_Object* ewkView, Ewk_Download_Job*, Ewk_W a/Source/WebKit2/UIProcess/API/efl/ewk_view_private.h_sec1
59
void ewk_view_download_job_finished(Evas_Object* ewkView, Ewk_Download_Job*);
59
void ewk_view_download_job_finished(Evas_Object* ewkView, Ewk_Download_Job*);
60
void ewk_view_download_job_requested(Evas_Object* ewkView, Ewk_Download_Job*);
60
void ewk_view_download_job_requested(Evas_Object* ewkView, Ewk_Download_Job*);
61
void ewk_view_form_submission_request_new(Evas_Object* ewkView, Ewk_Form_Submission_Request*);
61
void ewk_view_form_submission_request_new(Evas_Object* ewkView, Ewk_Form_Submission_Request*);
62
#if ENABLE(FULLSCREEN_API)
63
void ewk_view_full_screen_enter(Evas_Object* ewkView);
64
void ewk_view_full_screen_exit(Evas_Object* ewkView);
65
#endif
62
void ewk_view_image_data_set(Evas_Object* ewkView, void* imageData, const WebCore::IntSize& size);
66
void ewk_view_image_data_set(Evas_Object* ewkView, void* imageData, const WebCore::IntSize& size);
63
void ewk_view_load_error(Evas_Object* ewkView, const Ewk_Web_Error* error);
67
void ewk_view_load_error(Evas_Object* ewkView, const Ewk_Web_Error* error);
64
void ewk_view_load_finished(Evas_Object* ewkView);
68
void ewk_view_load_finished(Evas_Object* ewkView);
- a/Source/WebKit2/UIProcess/efl/WebFullScreenManagerProxyEfl.cpp -2 / +13 lines
Lines 25-30 a/Source/WebKit2/UIProcess/efl/WebFullScreenManagerProxyEfl.cpp_sec1
25
25
26
#include "config.h"
26
#include "config.h"
27
#include "WebFullScreenManagerProxy.h"
27
#include "WebFullScreenManagerProxy.h"
28
#include "ewk_view_private.h"
28
29
29
#if ENABLE(FULLSCREEN_API)
30
#if ENABLE(FULLSCREEN_API)
30
31
Lines 52-63 bool WebFullScreenManagerProxy::isFullScreen() a/Source/WebKit2/UIProcess/efl/WebFullScreenManagerProxyEfl.cpp_sec2
52
53
53
void WebFullScreenManagerProxy::enterFullScreen()
54
void WebFullScreenManagerProxy::enterFullScreen()
54
{
55
{
55
    notImplemented();
56
    if (!m_webView)
57
        return;
58
59
    willEnterFullScreen();
60
    ewk_view_full_screen_enter(m_webView);
61
    didEnterFullScreen();
56
}
62
}
57
63
58
void WebFullScreenManagerProxy::exitFullScreen()
64
void WebFullScreenManagerProxy::exitFullScreen()
59
{
65
{
60
    notImplemented();
66
    if (!m_webView)
67
        return;
68
69
    willExitFullScreen();
70
    ewk_view_full_screen_exit(m_webView);
71
    didExitFullScreen();
61
}
72
}
62
73
63
void WebFullScreenManagerProxy::beganEnterFullScreen(const IntRect& initialFrame, const IntRect& finalFrame)
74
void WebFullScreenManagerProxy::beganEnterFullScreen(const IntRect& initialFrame, const IntRect& finalFrame)
- a/Tools/ChangeLog +14 lines
Lines 1-3 a/Tools/ChangeLog_sec1
1
2012-09-05  Alexander Shalamov  <alexander.shalamov@intel.com>
2
3
        [EFL][WK2] Add fullscreen enter / exit signals to the ewk_view API
4
        https://bugs.webkit.org/show_bug.cgi?id=92362
5
6
        Reviewed by NOBODY (OOPS!).
7
8
        Listen to fullscreen request events and handle them in EFL MiniBrowser.
9
10
        * MiniBrowser/efl/main.c:
11
        (on_fullscreen_enter):
12
        (on_fullscreen_exit):
13
        (browserCreate):
14
1
2012-09-03  Ryuan Choi  <ryuan.choi@samsung.com>
15
2012-09-03  Ryuan Choi  <ryuan.choi@samsung.com>
2
16
3
        [EFL] Change the focus when the web view is clicked in MiniBrowser and EWebLauncher
17
        [EFL] Change the focus when the web view is clicked in MiniBrowser and EWebLauncher
- a/Tools/MiniBrowser/efl/main.c +25 lines
Lines 23-28 a/Tools/MiniBrowser/efl/main.c_sec1
23
#include <Ecore_Evas.h>
23
#include <Ecore_Evas.h>
24
#include <Eina.h>
24
#include <Eina.h>
25
#include <Evas.h>
25
#include <Evas.h>
26
#ifdef HAVE_ECORE_X
27
#include <Ecore_X.h>
28
#endif
26
29
27
static const int DEFAULT_WIDTH = 800;
30
static const int DEFAULT_WIDTH = 800;
28
static const int DEFAULT_HEIGHT = 600;
31
static const int DEFAULT_HEIGHT = 600;
Lines 202-207 on_error(void *user_data, Evas_Object *webview, void *event_info) a/Tools/MiniBrowser/efl/main.c_sec2
202
    eina_strbuf_free(buffer);
205
    eina_strbuf_free(buffer);
203
}
206
}
204
207
208
static void
209
on_fullscreen_enter(void *user_data, Evas_Object *webview, void *event_info)
210
{
211
#ifdef HAVE_ECORE_X
212
    MiniBrowser *app = (MiniBrowser *)user_data;
213
    Ecore_Window window = ecore_evas_window_get(app->ee);
214
    ecore_x_netwm_state_request_send((Ecore_X_Window)window, 0, ECORE_X_WINDOW_STATE_UNKNOWN, ECORE_X_WINDOW_STATE_FULLSCREEN, EINA_TRUE);
215
#endif
216
}
217
218
static void
219
on_fullscreen_exit(void *user_data, Evas_Object *webview, void *event_info)
220
{
221
#ifdef HAVE_ECORE_X
222
    MiniBrowser *app = (MiniBrowser *)user_data;
223
    Ecore_Window window = ecore_evas_window_get(app->ee);
224
    ecore_x_netwm_state_request_send((Ecore_X_Window)window, 0, ECORE_X_WINDOW_STATE_UNKNOWN, ECORE_X_WINDOW_STATE_FULLSCREEN, EINA_FALSE);
225
#endif
226
}
227
205
static int
228
static int
206
quit(Eina_Bool success, const char *msg)
229
quit(Eina_Bool success, const char *msg)
207
{
230
{
Lines 250-255 static MiniBrowser *browserCreate(const char *url, const char *engine) a/Tools/MiniBrowser/efl/main.c_sec3
250
    evas_object_smart_callback_add(app->browser, "load,progress", on_progress, app);
273
    evas_object_smart_callback_add(app->browser, "load,progress", on_progress, app);
251
    evas_object_smart_callback_add(app->browser, "title,changed", on_title_changed, app);
274
    evas_object_smart_callback_add(app->browser, "title,changed", on_title_changed, app);
252
    evas_object_smart_callback_add(app->browser, "uri,changed", on_url_changed, app);
275
    evas_object_smart_callback_add(app->browser, "uri,changed", on_url_changed, app);
276
    evas_object_smart_callback_add(app->browser, "fullscreen,enter", on_fullscreen_enter, app);
277
    evas_object_smart_callback_add(app->browser, "fullscreen,exit", on_fullscreen_exit, app);
253
278
254
    evas_object_event_callback_add(app->browser, EVAS_CALLBACK_KEY_DOWN, on_key_down, app);
279
    evas_object_event_callback_add(app->browser, EVAS_CALLBACK_KEY_DOWN, on_key_down, app);
255
    evas_object_event_callback_add(app->browser, EVAS_CALLBACK_MOUSE_DOWN, on_mouse_down, app);
280
    evas_object_event_callback_add(app->browser, EVAS_CALLBACK_MOUSE_DOWN, on_mouse_down, app);

Return to Bug 92362