Changeset 166915 in webkit
- Timestamp:
- Apr 8, 2014 12:14:20 AM (10 years ago)
- Location:
- trunk/Source
- Files:
-
- 9 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Source/WebCore/ChangeLog
r166909 r166915 1 2014-04-08 Gyuyoung Kim <gyuyoung.kim@samsung.com> 2 3 Change NavigatorContentUtils client ownership from port side to NavigatorContentUtils 4 https://bugs.webkit.org/show_bug.cgi?id=131299 5 6 Reviewed by Darin Adler. 7 8 EFL and GTK ports have managed own client of NavigatorContentUtils though it is only passed to 9 NavigatorContentUtils. The NavigatorContentUtils has used the client to call port functions. So, 10 there is no reason port implementation needs to manage the ownership. To manage the client is 11 unnecessary work in current implementation. 12 13 No new tests, no behavior changes. 14 15 * Modules/navigatorcontentutils/NavigatorContentUtils.cpp: 16 (WebCore::NavigatorContentUtils::create): 17 (WebCore::provideNavigatorContentUtilsTo): 18 * Modules/navigatorcontentutils/NavigatorContentUtils.h: 19 * Modules/navigatorcontentutils/NavigatorContentUtilsClient.h: 20 1 21 2014-04-07 Zoltan Horvath <zoltan@webkit.org> 2 22 -
trunk/Source/WebCore/Modules/navigatorcontentutils/NavigatorContentUtils.cpp
r165723 r166915 127 127 } 128 128 129 PassRef<NavigatorContentUtils> NavigatorContentUtils::create( NavigatorContentUtilsClient*client)130 { 131 return adoptRef(*new NavigatorContentUtils( client));129 PassRef<NavigatorContentUtils> NavigatorContentUtils::create(std::unique_ptr<NavigatorContentUtilsClient> client) 130 { 131 return adoptRef(*new NavigatorContentUtils(std::move(client))); 132 132 } 133 133 … … 220 220 } 221 221 222 void provideNavigatorContentUtilsTo(Page* page, NavigatorContentUtilsClient*client)223 { 224 RefCountedSupplement<Page, NavigatorContentUtils>::provideTo(page, NavigatorContentUtils::supplementName(), NavigatorContentUtils::create( client));222 void provideNavigatorContentUtilsTo(Page* page, std::unique_ptr<NavigatorContentUtilsClient> client) 223 { 224 RefCountedSupplement<Page, NavigatorContentUtils>::provideTo(page, NavigatorContentUtils::supplementName(), NavigatorContentUtils::create(std::move(client))); 225 225 } 226 226 -
trunk/Source/WebCore/Modules/navigatorcontentutils/NavigatorContentUtils.h
r166130 r166915 56 56 #endif 57 57 58 static PassRef<NavigatorContentUtils> create( NavigatorContentUtilsClient*);58 static PassRef<NavigatorContentUtils> create(std::unique_ptr<NavigatorContentUtilsClient>); 59 59 60 60 private: 61 explicit NavigatorContentUtils( NavigatorContentUtilsClient*client)62 : m_client( client)61 explicit NavigatorContentUtils(std::unique_ptr<NavigatorContentUtilsClient> client) 62 : m_client(std::move(client)) 63 63 { } 64 64 65 NavigatorContentUtilsClient* client() { return m_client ; }65 NavigatorContentUtilsClient* client() { return m_client.get(); } 66 66 67 NavigatorContentUtilsClient*m_client;67 std::unique_ptr<NavigatorContentUtilsClient> m_client; 68 68 }; 69 69 -
trunk/Source/WebCore/Modules/navigatorcontentutils/NavigatorContentUtilsClient.h
r164568 r166915 53 53 }; 54 54 55 void provideNavigatorContentUtilsTo(Page*, NavigatorContentUtilsClient*);55 void provideNavigatorContentUtilsTo(Page*, std::unique_ptr<NavigatorContentUtilsClient>); 56 56 57 57 } -
trunk/Source/WebKit/efl/ChangeLog
r166889 r166915 1 2014-04-08 Gyuyoung Kim <gyuyoung.kim@samsung.com> 2 3 Change NavigatorContentUtils client ownership from port side to NavigatorContentUtils 4 https://bugs.webkit.org/show_bug.cgi?id=131299 5 6 Reviewed by Darin Adler. 7 8 EFL and GTK ports have managed own client of NavigatorContentUtils though it is only passed to 9 NavigatorContentUtils. The NavigatorContentUtils has used the client to call port functions. So, 10 there is no reason port implementation needs to manage the ownership. To manage the client is 11 unnecessary work in current implementation. 12 13 * ewk/ewk_view.cpp: 14 (_ewk_view_priv_new): 15 1 16 2014-04-07 Hyowon Kim <hw1008.kim@samsung.com> 2 17 -
trunk/Source/WebKit/efl/ewk/ewk_view.cpp
r166866 r166915 260 260 WebCore::ColorChooserClient* colorChooserClient; 261 261 #endif 262 #if ENABLE(NAVIGATOR_CONTENT_UTILS) || ENABLE(CUSTOM_SCHEME_HANDLER)263 std::unique_ptr<WebCore::NavigatorContentUtilsClientEfl> navigatorContentUtilsClient;264 #endif265 262 struct { 266 263 Ewk_Menu menu; … … 688 685 689 686 #if ENABLE(NAVIGATOR_CONTENT_UTILS) 690 priv->navigatorContentUtilsClient = std::make_unique<WebCore::NavigatorContentUtilsClientEfl>(smartData->self); 691 WebCore::provideNavigatorContentUtilsTo(priv->page.get(), priv->navigatorContentUtilsClient.get()); 687 WebCore::provideNavigatorContentUtilsTo(priv->page.get(), std::make_unique<WebCore::NavigatorContentUtilsClientEfl>(smartData->self)); 692 688 #endif 693 689 -
trunk/Source/WebKit/gtk/ChangeLog
r166889 r166915 1 2014-04-08 Gyuyoung Kim <gyuyoung.kim@samsung.com> 2 3 Change NavigatorContentUtils client ownership from port side to NavigatorContentUtils 4 https://bugs.webkit.org/show_bug.cgi?id=131299 5 6 Reviewed by Darin Adler. 7 8 EFL and GTK ports have managed own client of NavigatorContentUtils though it is only passed to 9 NavigatorContentUtils. The NavigatorContentUtils has used the client to call port functions. So, 10 there is no reason port implementation needs to manage the ownership. To manage the client is 11 unnecessary work in current implementation. 12 13 * webkit/webkitwebview.cpp: 14 (webkit_web_view_init): 15 * webkit/webkitwebviewprivate.h: 16 1 17 2014-04-07 Hyowon Kim <hw1008.kim@samsung.com> 2 18 -
trunk/Source/WebKit/gtk/webkit/webkitwebview.cpp
r166661 r166915 3871 3871 3872 3872 #if ENABLE(NAVIGATOR_CONTENT_UTILS) 3873 priv->navigatorContentUtilsClient = std::make_unique<WebKit::NavigatorContentUtilsClient>(); 3874 WebCore::provideNavigatorContentUtilsTo(priv->corePage, priv->navigatorContentUtilsClient.get()); 3873 WebCore::provideNavigatorContentUtilsTo(priv->corePage, std::make_unique<WebKit::NavigatorContentUtilsClient>()); 3875 3874 #endif 3876 3875 -
trunk/Source/WebKit/gtk/webkit/webkitwebviewprivate.h
r165253 r166915 117 117 std::unique_ptr<WebCore::GeolocationClientMock> geolocationClientMock; 118 118 #endif 119 120 #if ENABLE(NAVIGATOR_CONTENT_UTILS)121 std::unique_ptr<WebKit::NavigatorContentUtilsClient> navigatorContentUtilsClient;122 #endif123 119 }; 124 120
Note: See TracChangeset
for help on using the changeset viewer.