Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(523)

Side by Side Diff: content/browser/web_contents/web_contents_impl.h

Issue 1107333002: Wake Lock API implementation (Chromium part) (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef CONTENT_BROWSER_WEB_CONTENTS_WEB_CONTENTS_IMPL_H_ 5 #ifndef CONTENT_BROWSER_WEB_CONTENTS_WEB_CONTENTS_IMPL_H_
6 #define CONTENT_BROWSER_WEB_CONTENTS_WEB_CONTENTS_IMPL_H_ 6 #define CONTENT_BROWSER_WEB_CONTENTS_WEB_CONTENTS_IMPL_H_
7 7
8 #include <map> 8 #include <map>
9 #include <set> 9 #include <set>
10 #include <string> 10 #include <string>
(...skipping 47 matching lines...) Expand 10 before | Expand all | Expand 10 after
58 class MediaWebContentsObserver; 58 class MediaWebContentsObserver;
59 class PluginContentOriginWhitelist; 59 class PluginContentOriginWhitelist;
60 class PowerSaveBlocker; 60 class PowerSaveBlocker;
61 class RenderViewHost; 61 class RenderViewHost;
62 class RenderViewHostDelegateView; 62 class RenderViewHostDelegateView;
63 class RenderWidgetHostImpl; 63 class RenderWidgetHostImpl;
64 class SavePackage; 64 class SavePackage;
65 class ScreenOrientationDispatcherHost; 65 class ScreenOrientationDispatcherHost;
66 class SiteInstance; 66 class SiteInstance;
67 class TestWebContents; 67 class TestWebContents;
68 class WakeLockServiceContext;
68 class WebContentsAudioMuter; 69 class WebContentsAudioMuter;
69 class WebContentsDelegate; 70 class WebContentsDelegate;
70 class WebContentsImpl; 71 class WebContentsImpl;
71 class WebContentsObserver; 72 class WebContentsObserver;
72 class WebContentsView; 73 class WebContentsView;
73 class WebContentsViewDelegate; 74 class WebContentsViewDelegate;
74 struct AXEventNotificationDetails; 75 struct AXEventNotificationDetails;
75 struct ColorSuggestion; 76 struct ColorSuggestion;
76 struct FaviconURL; 77 struct FaviconURL;
77 struct LoadNotificationDetails; 78 struct LoadNotificationDetails;
(...skipping 103 matching lines...) Expand 10 before | Expand all | Expand 10 after
181 182
182 // Notify observers that the web contents has been focused. 183 // Notify observers that the web contents has been focused.
183 void NotifyWebContentsFocused(); 184 void NotifyWebContentsFocused();
184 185
185 WebContentsView* GetView() const; 186 WebContentsView* GetView() const;
186 187
187 ScreenOrientationDispatcherHost* screen_orientation_dispatcher_host() { 188 ScreenOrientationDispatcherHost* screen_orientation_dispatcher_host() {
188 return screen_orientation_dispatcher_host_.get(); 189 return screen_orientation_dispatcher_host_.get();
189 } 190 }
190 191
192 WakeLockServiceContext* wake_lock_service_context() {
193 return wake_lock_service_context_.get();
194 }
195
191 bool should_normally_be_visible() { return should_normally_be_visible_; } 196 bool should_normally_be_visible() { return should_normally_be_visible_; }
192 197
193 // Indicate if the window has been occluded, and pass this to the views, only 198 // Indicate if the window has been occluded, and pass this to the views, only
194 // if there is no active capture going on (otherwise it is dropped on the 199 // if there is no active capture going on (otherwise it is dropped on the
195 // floor). 200 // floor).
196 void WasOccluded(); 201 void WasOccluded();
197 void WasUnOccluded(); 202 void WasUnOccluded();
198 203
199 // Broadcasts the mode change to all frames. 204 // Broadcasts the mode change to all frames.
200 void SetAccessibilityMode(AccessibilityMode mode); 205 void SetAccessibilityMode(AccessibilityMode mode);
(...skipping 1065 matching lines...) Expand 10 before | Expand all | Expand 10 after
1266 bool force_disable_overscroll_content_; 1271 bool force_disable_overscroll_content_;
1267 1272
1268 // Whether the last JavaScript dialog shown was suppressed. Used for testing. 1273 // Whether the last JavaScript dialog shown was suppressed. Used for testing.
1269 bool last_dialog_suppressed_; 1274 bool last_dialog_suppressed_;
1270 1275
1271 scoped_ptr<GeolocationServiceContext> geolocation_service_context_; 1276 scoped_ptr<GeolocationServiceContext> geolocation_service_context_;
1272 1277
1273 scoped_ptr<ScreenOrientationDispatcherHost> 1278 scoped_ptr<ScreenOrientationDispatcherHost>
1274 screen_orientation_dispatcher_host_; 1279 screen_orientation_dispatcher_host_;
1275 1280
1281 scoped_ptr<WakeLockServiceContext> wake_lock_service_context_;
1282
1276 scoped_ptr<ManifestManagerHost> manifest_manager_host_; 1283 scoped_ptr<ManifestManagerHost> manifest_manager_host_;
1277 1284
1278 // The accessibility mode for all frames. This is queried when each frame 1285 // The accessibility mode for all frames. This is queried when each frame
1279 // is created, and broadcast to all frames when it changes. 1286 // is created, and broadcast to all frames when it changes.
1280 AccessibilityMode accessibility_mode_; 1287 AccessibilityMode accessibility_mode_;
1281 1288
1282 // Created on-demand to mute all audio output from this WebContents. 1289 // Created on-demand to mute all audio output from this WebContents.
1283 scoped_ptr<WebContentsAudioMuter> audio_muter_; 1290 scoped_ptr<WebContentsAudioMuter> audio_muter_;
1284 1291
1285 bool virtual_keyboard_requested_; 1292 bool virtual_keyboard_requested_;
(...skipping 21 matching lines...) Expand all
1307 // Adds/removes a callback called on creation of each new WebContents. 1314 // Adds/removes a callback called on creation of each new WebContents.
1308 static void AddCreatedCallbackForTesting(const CreatedCallback& callback); 1315 static void AddCreatedCallbackForTesting(const CreatedCallback& callback);
1309 static void RemoveCreatedCallbackForTesting(const CreatedCallback& callback); 1316 static void RemoveCreatedCallbackForTesting(const CreatedCallback& callback);
1310 1317
1311 DISALLOW_COPY_AND_ASSIGN(FriendZone); 1318 DISALLOW_COPY_AND_ASSIGN(FriendZone);
1312 }; 1319 };
1313 1320
1314 } // namespace content 1321 } // namespace content
1315 1322
1316 #endif // CONTENT_BROWSER_WEB_CONTENTS_WEB_CONTENTS_IMPL_H_ 1323 #endif // CONTENT_BROWSER_WEB_CONTENTS_WEB_CONTENTS_IMPL_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698