Changeset 160445 in webkit
- Timestamp:
- Dec 11, 2013 10:23:02 AM (10 years ago)
- Location:
- trunk
- Files:
-
- 2 added
- 5 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Source/WebKit2/ChangeLog
r160444 r160445 1 2013-12-11 José Dapena Paz <jdapena@igalia.com> and Zan Dobersek <zdobersek@igalia.com> 2 3 [GTK][WK2] Add the WebKitBatteryProvider class 4 https://bugs.webkit.org/show_bug.cgi?id=115720 5 6 Reviewed by Martin Robinson. 7 8 This patch adds the WebKitBatteryProvider class which sets up a BatteryProviderUPower instance, 9 controlling the provider's activity when instrumented to do so by the WebBatteryManagerProxy 10 and relaying the battery status updates from the battery provider to the battery manager. 11 12 * GNUmakefile.list.am: Add the build targets for the new source files. 13 * UIProcess/API/gtk/WebKitBatteryProvider.cpp: Added. 14 (toBatteryProvider): A helper inline method that casts the client info to the battery provider instance. 15 (startUpdatingCallback): Relays the instruction to the WebKitBattery instance. 16 (stopUpdatingCallback): Ditto. 17 (WebKitBatteryProvider::create): 18 (WebKitBatteryProvider::WebKitBatteryProvider): Set up a WKBatteryProvider and set it to the passed-in battery manager. 19 (WebKitBatteryProvider::~WebKitBatteryProvider): Force the BatteryProviderUPower to stop updating. 20 (WebKitBatteryProvider::startUpdating): Relays the instruction to the BatteryProviderUPower instance. 21 (WebKitBatteryProvider::stopUpdating): Ditto. 22 (WebKitBatteryProvider::notifyBatteryStatusUnavailable): Update the battery manager with the new status that 23 has the default values that are to be used when the implementation cannot determine the battery status (as per 24 the Battery Status API specification). 25 (WebKitBatteryProvider::notifyBatteryStatusUpdated): Update the battery status. 26 * UIProcess/API/gtk/WebKitBatteryProvider.h: Added. 27 (WebKitBatteryProvider): Define the WebKitBatteryProvider reference-counted interface that also inherits from the 28 BatteryProviderUPowerClient interface. 29 * UIProcess/API/gtk/WebKitWebContext.cpp: 30 (_WebKitWebContextPrivate): Add a WebKitBatteryProvider member variable to the struct. 31 (createDefaultWebContext): Create a new battery provider when initializing the default web context. 32 1 33 2013-12-11 José Dapena Paz <jdapena@igalia.com> and Zan Dobersek <zdobersek@igalia.com> 2 34 -
trunk/Source/WebKit2/GNUmakefile.list.am
r160409 r160445 725 725 Source/WebKit2/UIProcess/API/gtk/WebKitBackForwardListItem.cpp \ 726 726 Source/WebKit2/UIProcess/API/gtk/WebKitBackForwardListPrivate.h \ 727 Source/WebKit2/UIProcess/API/gtk/WebKitBatteryProvider.cpp \ 728 Source/WebKit2/UIProcess/API/gtk/WebKitBatteryProvider.h \ 727 729 Source/WebKit2/UIProcess/API/gtk/WebKitCertificateInfo.cpp \ 728 730 Source/WebKit2/UIProcess/API/gtk/WebKitCertificateInfo.h \ -
trunk/Source/WebKit2/UIProcess/API/gtk/WebKitWebContext.cpp
r160358 r160445 21 21 #include "WebKitWebContext.h" 22 22 23 #include "WebBatteryManagerProxy.h" 23 24 #include "WebCertificateInfo.h" 24 25 #include "WebCookieManagerProxy.h" 25 26 #include "WebGeolocationManagerProxy.h" 27 #include "WebKitBatteryProvider.h" 26 28 #include "WebKitCertificateInfoPrivate.h" 27 29 #include "WebKitCookieManagerPrivate.h" … … 140 142 RefPtr<WebKitGeolocationProvider> geolocationProvider; 141 143 #endif 144 #if ENABLE(BATTERY_STATUS) 145 RefPtr<WebKitBatteryProvider> batteryProvider; 146 #endif 142 147 #if ENABLE(SPELLCHECK) 143 148 OwnPtr<WebKitTextChecker> textChecker; … … 212 217 priv->geolocationProvider = WebKitGeolocationProvider::create(priv->context->supplement<WebGeolocationManagerProxy>()); 213 218 #endif 219 #if ENABLE(BATTERY_STATUS) 220 priv->batteryProvider = WebKitBatteryProvider::create(priv->context->supplement<WebBatteryManagerProxy>()); 221 #endif 214 222 #if ENABLE(SPELLCHECK) 215 223 priv->textChecker = WebKitTextChecker::create(); -
trunk/Tools/ChangeLog
r160439 r160445 1 2013-12-11 José Dapena Paz <jdapena@igalia.com> and Zan Dobersek <zdobersek@igalia.com> 2 3 [GTK][WK2] Add the WebKitBatteryProvider class 4 https://bugs.webkit.org/show_bug.cgi?id=115720 5 6 Reviewed by Martin Robinson. 7 8 * gtk/generate-gtkdoc: 9 (get_webkit2_options): Ignore the WebKitBatteryProvider source files when generating the documentation. 10 1 11 2013-12-11 Mark Rowe <mrowe@apple.com> 2 12 -
trunk/Tools/gtk/generate-gtkdoc
r159614 r160445 105 105 glob.glob(injected_bundle_src_path('*Private.h')) + \ 106 106 glob.glob(src_path('*Client*')) + \ 107 glob.glob(src_path('WebKitAuthenticationDialog.*')) + \ 108 glob.glob(src_path('WebKitBatteryProvider.*')) + \ 107 109 glob.glob(src_path('WebKitGeolocationProvider.*')) + \ 108 110 glob.glob(src_path('WebKitTextChecker.*')) + \ 109 glob.glob(src_path('WebKitAuthenticationDialog.*')) + \110 111 glob.glob(src_path('WebKitWebViewBaseAccessible.*')) + \ 111 112 glob.glob(src_path('WebViewBaseInputMethodFilter.*')) + \
Note: See TracChangeset
for help on using the changeset viewer.