Changeset 65163 in webkit
- Timestamp:
- Aug 11, 2010 10:14:54 AM (14 years ago)
- Location:
- trunk/WebKit/efl
- Files:
-
- 5 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/WebKit/efl/ChangeLog
r65122 r65163 1 2010-08-11 Ryuan Choi <ryuan.choi@samsung.com> 2 3 Reviewed by Antonio Gomes. 4 5 Implementation dispatchDecidePolicyForNavigationAction 6 https://bugs.webkit.org/show_bug.cgi?id=43544 7 8 Add ewk_view_navigation_policy_decision to decide whether url which 9 user clicked will be loaded or not. 10 11 * WebCoreSupport/FrameLoaderClientEfl.cpp: 12 (WebCore::FrameLoaderClientEfl::dispatchDecidePolicyForNavigationAction): 13 * ewk/ewk_private.h: 14 * ewk/ewk_view.cpp: 15 (ewk_view_navigation_policy_decision): 16 * ewk/ewk_view.h: 17 1 18 2010-08-10 Ryuan Choi <ryuan.choi@samsung.com> 2 19 -
trunk/WebKit/efl/WebCoreSupport/FrameLoaderClientEfl.cpp
r62787 r65163 355 355 // if not acceptNavigationRequest - look at Qt -> PolicyIgnore; 356 356 // FIXME: do proper check and only reset forms when on PolicyIgnore 357 Frame* f = ewk_frame_core_get(m_frame); 358 f->loader()->resetMultipleFormSubmissionProtection(); 359 callPolicyFunction(function, PolicyUse); 357 char* url = strdup(resourceRequest.url().prettyURL().utf8().data()); 358 Ewk_Frame_Resource_Request request = { url, 0 }; 359 Eina_Bool ret = ewk_view_navigation_policy_decision(m_view, &request); 360 free(url); 361 362 PolicyAction policy; 363 if (!ret) 364 policy = PolicyIgnore; 365 else { 366 if (action.type() == NavigationTypeFormSubmitted || action.type() == NavigationTypeFormResubmitted) { 367 Frame* f = ewk_frame_core_get(m_frame); 368 f->loader()->resetMultipleFormSubmissionProtection(); 369 } 370 policy = PolicyUse; 371 } 372 callPolicyFunction(function, policy); 360 373 } 361 374 -
trunk/WebKit/efl/ewk/ewk_private.h
r65021 r65163 149 149 WTF::PassRefPtr<WebCore::Widget> ewk_frame_plugin_create(Evas_Object* o, const WebCore::IntSize& pluginSize, WebCore::HTMLPlugInElement* element, const WebCore::KURL& url, const WTF::Vector<WTF::String>& paramNames, const WTF::Vector<WTF::String>& paramValues, const WTF::String& mimeType, bool loadManually); 150 150 151 Eina_Bool ewk_view_navigation_policy_decision(Evas_Object* o, Ewk_Frame_Resource_Request* request); 152 151 153 #ifdef __cplusplus 152 154 -
trunk/WebKit/efl/ewk/ewk_view.cpp
r65122 r65163 3981 3981 return priv->settings.zoom_range.user_scalable; 3982 3982 } 3983 3984 /** 3985 * @internal 3986 * Reports a requeset will be loaded. It's client responsibility to decide if 3987 * request would be used. If @return is true, loader will try to load. Else, 3988 * Loader ignore action of request. 3989 * 3990 * @param o View to load 3991 * @param request Request which contain url to navigate 3992 */ 3993 Eina_Bool ewk_view_navigation_policy_decision(Evas_Object* o, Ewk_Frame_Resource_Request* request) 3994 { 3995 EWK_VIEW_SD_GET_OR_RETURN(o, sd, EINA_TRUE); 3996 EINA_SAFETY_ON_NULL_RETURN_VAL(sd->api, EINA_TRUE); 3997 3998 if (!sd->api->navigation_policy_decision) 3999 return EINA_TRUE; 4000 4001 return sd->api->navigation_policy_decision(sd, request); 4002 } -
trunk/WebKit/efl/ewk/ewk_view.h
r63978 r65163 22 22 #define ewk_view_h 23 23 24 #include "ewk_frame.h" 24 25 #include "ewk_history.h" 25 26 #include "ewk_window_features.h" … … 134 135 135 136 Eina_Bool (*run_open_panel)(Ewk_View_Smart_Data *sd, Evas_Object *frame, Eina_Bool allows_multiple_files, const Eina_List *suggested_filenames, Eina_List **selected_filenames); 137 138 Eina_Bool (*navigation_policy_decision)(Ewk_View_Smart_Data *sd, Ewk_Frame_Resource_Request *request); 136 139 }; 137 140
Note: See TracChangeset
for help on using the changeset viewer.