From: staikos@webkit.org Date: Tue, 3 Jul 2012 16:00:22 +0000 (+0000) Subject: [BlackBerry] Enable Custom Scheme Handlers for BlackBerry. X-Git-Tag: 070512121124~122 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=a9fe4063b7452a0fb78d82afcd6e4230bcd56a14;p=profile%2Fivi%2Fwebkit-efl.git [BlackBerry] Enable Custom Scheme Handlers for BlackBerry. https://bugs.webkit.org/show_bug.cgi?id=90422 Reviewed by Rob Buis. .: * Source/cmake/OptionsBlackBerry.cmake: Source/WebCore: * page/NavigatorRegisterProtocolHandler.cpp: (WebCore::initProtocolHandlerWhitelist): Disable the overrides as they're undesired by BlackBerry Source/WebKit/blackberry: * WebCoreSupport/ChromeClientBlackBerry.cpp: (WebCore): (WebCore::ChromeClientBlackBerry::isProtocolHandlerRegistered): (WebCore::ChromeClientBlackBerry::unregisterProtocolHandler): * WebCoreSupport/ChromeClientBlackBerry.h: (ChromeClientBlackBerry): Tools: * Scripts/webkitperl/FeatureList.pm: git-svn-id: http://svn.webkit.org/repository/webkit/trunk@121774 268f45cc-cd09-0410-ab3c-d52691b4dbfc --- diff --git a/ChangeLog b/ChangeLog index 47741e5..554d84c 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,5 +1,14 @@ 2012-07-03 George Staikos + [BlackBerry] Enable Custom Scheme Handlers for BlackBerry. + https://bugs.webkit.org/show_bug.cgi?id=90422 + + Reviewed by Rob Buis. + + * Source/cmake/OptionsBlackBerry.cmake: + +2012-07-03 George Staikos + [BlackBerry] Enable RegisterProtocolHandler for BlackBerry. https://bugs.webkit.org/show_bug.cgi?id=90422 diff --git a/Source/WebCore/ChangeLog b/Source/WebCore/ChangeLog index 56481e9..47b6af0 100644 --- a/Source/WebCore/ChangeLog +++ b/Source/WebCore/ChangeLog @@ -1,3 +1,14 @@ +2012-07-03 George Staikos + + [BlackBerry] Enable Custom Scheme Handlers for BlackBerry. + https://bugs.webkit.org/show_bug.cgi?id=90422 + + Reviewed by Rob Buis. + + * page/NavigatorRegisterProtocolHandler.cpp: + (WebCore::initProtocolHandlerWhitelist): Disable the overrides as + they're undesired by BlackBerry + 2012-07-03 Eugene Klyuchnikov Web Inspector: Forward message loop instrumentation data to frontend. diff --git a/Source/WebCore/page/NavigatorRegisterProtocolHandler.cpp b/Source/WebCore/page/NavigatorRegisterProtocolHandler.cpp index dde5d79..0d5eb89 100644 --- a/Source/WebCore/page/NavigatorRegisterProtocolHandler.cpp +++ b/Source/WebCore/page/NavigatorRegisterProtocolHandler.cpp @@ -46,6 +46,7 @@ static void initProtocolHandlerWhitelist() { protocolWhitelist = new HashSet; static const char* protocols[] = { +#if !PLATFORM(BLACKBERRY) "irc", "mailto", "mms", @@ -56,6 +57,7 @@ static void initProtocolHandlerWhitelist() "tel", "urn", "webcal", +#endif }; for (size_t i = 0; i < WTF_ARRAY_LENGTH(protocols); ++i) protocolWhitelist->add(protocols[i]); diff --git a/Source/WebKit/blackberry/ChangeLog b/Source/WebKit/blackberry/ChangeLog index f02b2eb..9a99c35 100644 --- a/Source/WebKit/blackberry/ChangeLog +++ b/Source/WebKit/blackberry/ChangeLog @@ -1,5 +1,19 @@ 2012-07-03 George Staikos + [BlackBerry] Enable Custom Scheme Handlers for BlackBerry. + https://bugs.webkit.org/show_bug.cgi?id=90422 + + Reviewed by Rob Buis. + + * WebCoreSupport/ChromeClientBlackBerry.cpp: + (WebCore): + (WebCore::ChromeClientBlackBerry::isProtocolHandlerRegistered): + (WebCore::ChromeClientBlackBerry::unregisterProtocolHandler): + * WebCoreSupport/ChromeClientBlackBerry.h: + (ChromeClientBlackBerry): + +2012-07-03 George Staikos + [BlackBerry] Enable RegisterProtocolHandler for BlackBerry. https://bugs.webkit.org/show_bug.cgi?id=90422 diff --git a/Source/WebKit/blackberry/WebCoreSupport/ChromeClientBlackBerry.cpp b/Source/WebKit/blackberry/WebCoreSupport/ChromeClientBlackBerry.cpp index 924f757..685df5f 100644 --- a/Source/WebKit/blackberry/WebCoreSupport/ChromeClientBlackBerry.cpp +++ b/Source/WebKit/blackberry/WebCoreSupport/ChromeClientBlackBerry.cpp @@ -809,6 +809,16 @@ PassOwnPtr ChromeClientBlackBerry::createColorChooser(ColorChooser return nullptr; } +#if ENABLE(CUSTOM_SCHEME_HANDLER) +CustomHandlersState ChromeClientBlackBerry::isProtocolHandlerRegistered(const String&, const String&, const String&) +{ + return CustomHandlersDeclined; +} + +void ChromeClientBlackBerry::unregisterProtocolHandler(const String&, const String&, const String&) +{ +} +#endif #if ENABLE(REGISTER_PROTOCOL_HANDLER) void ChromeClientBlackBerry::registerProtocolHandler(const WTF::String&, const WTF::String&, const WTF::String&, const WTF::String&) diff --git a/Source/WebKit/blackberry/WebCoreSupport/ChromeClientBlackBerry.h b/Source/WebKit/blackberry/WebCoreSupport/ChromeClientBlackBerry.h index a7ff88a..7df6efc 100644 --- a/Source/WebKit/blackberry/WebCoreSupport/ChromeClientBlackBerry.h +++ b/Source/WebKit/blackberry/WebCoreSupport/ChromeClientBlackBerry.h @@ -159,6 +159,11 @@ public: virtual void registerProtocolHandler(const WTF::String&, const WTF::String&, const WTF::String&, const WTF::String&); #endif +#if ENABLE(CUSTOM_SCHEME_HANDLER) + virtual CustomHandlersState isProtocolHandlerRegistered(const String&, const String&, const String&); + virtual void unregisterProtocolHandler(const String&, const String&, const String&); +#endif + BlackBerry::WebKit::WebPagePrivate* webPagePrivate() const { return m_webPagePrivate; } private: diff --git a/Source/cmake/OptionsBlackBerry.cmake b/Source/cmake/OptionsBlackBerry.cmake index 61f10c1..f6316b2 100644 --- a/Source/cmake/OptionsBlackBerry.cmake +++ b/Source/cmake/OptionsBlackBerry.cmake @@ -141,6 +141,7 @@ WEBKIT_OPTION_DEFAULT_PORT_VALUE(ENABLE_ANIMATION_API ON) WEBKIT_OPTION_DEFAULT_PORT_VALUE(ENABLE_ASSEMBLER_WX_EXCLUSIVE ON) WEBKIT_OPTION_DEFAULT_PORT_VALUE(ENABLE_BATTERY_STATUS ON) WEBKIT_OPTION_DEFAULT_PORT_VALUE(ENABLE_BLOB ON) +WEBKIT_OPTION_DEFAULT_PORT_VALUE(ENABLE_CUSTOM_SCHEME_HANDLER ON) WEBKIT_OPTION_DEFAULT_PORT_VALUE(ENABLE_DEVICE_ORIENTATION ON) WEBKIT_OPTION_DEFAULT_PORT_VALUE(ENABLE_DRAG_SUPPORT OFF) WEBKIT_OPTION_DEFAULT_PORT_VALUE(ENABLE_DOWNLOAD_ATTRIBUTE ON) diff --git a/Tools/ChangeLog b/Tools/ChangeLog index 7015ea0..110d4b0 100644 --- a/Tools/ChangeLog +++ b/Tools/ChangeLog @@ -1,5 +1,14 @@ 2012-07-03 George Staikos + [BlackBerry] Enable Custom Scheme Handlers for BlackBerry. + https://bugs.webkit.org/show_bug.cgi?id=90422 + + Reviewed by Rob Buis. + + * Scripts/webkitperl/FeatureList.pm: + +2012-07-03 George Staikos + [BlackBerry] Enable RegisterProtocolHandler for BlackBerry. https://bugs.webkit.org/show_bug.cgi?id=90422 diff --git a/Tools/Scripts/webkitperl/FeatureList.pm b/Tools/Scripts/webkitperl/FeatureList.pm index 7d191f5..434d87a 100644 --- a/Tools/Scripts/webkitperl/FeatureList.pm +++ b/Tools/Scripts/webkitperl/FeatureList.pm @@ -178,7 +178,7 @@ my @features = ( define => "ENABLE_CSS_VARIABLES", default => 0, value => \$cssVariablesSupport }, { option => "custom-scheme-handler", desc => "Toggle Custom Scheme Handler support", - define => "ENABLE_CUSTOM_SCHEME_HANDLER", default => 0, value => \$customSchemeHandlerSupport }, + define => "ENABLE_CUSTOM_SCHEME_HANDLER", default => isBlackBerry(), value => \$customSchemeHandlerSupport }, { option => "datalist", desc => "Toggle Datalist support", define => "ENABLE_DATALIST", default => isEfl(), value => \$datalistSupport },