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

Side by Side Diff: third_party/WebKit/Source/modules/wake_lock/ScreenWakeLock.h

Issue 2629593004: Disambiguate LifecycleObserver::contextDestroyed (Closed)
Patch Set: temp Created 3 years, 11 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 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 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 ScreenWakeLock_h 5 #ifndef ScreenWakeLock_h
6 #define ScreenWakeLock_h 6 #define ScreenWakeLock_h
7 7
8 #include "core/dom/ContextLifecycleObserver.h" 8 #include "core/dom/ContextLifecycleObserver.h"
9 #include "core/frame/LocalFrame.h" 9 #include "core/frame/LocalFrame.h"
10 #include "core/page/PageVisibilityObserver.h" 10 #include "core/page/PageVisibilityObserver.h"
(...skipping 23 matching lines...) Expand all
34 34
35 ~ScreenWakeLock() = default; 35 ~ScreenWakeLock() = default;
36 36
37 DECLARE_VIRTUAL_TRACE(); 37 DECLARE_VIRTUAL_TRACE();
38 38
39 private: 39 private:
40 explicit ScreenWakeLock(LocalFrame&); 40 explicit ScreenWakeLock(LocalFrame&);
41 41
42 // Inherited from PageVisibilityObserver. 42 // Inherited from PageVisibilityObserver.
43 void pageVisibilityChanged() override; 43 void pageVisibilityChanged() override;
44 void contextDestroyed() override; 44 void contextDestroyed(Page*) override;
45 // Inherited from ContextLifecycleObserver.
46 void contextDestroyed(ExecutionContext*) override;
45 47
46 bool keepAwake() const; 48 bool keepAwake() const;
47 void setKeepAwake(bool); 49 void setKeepAwake(bool);
48 50
49 static ScreenWakeLock* fromScreen(Screen&); 51 static ScreenWakeLock* fromScreen(Screen&);
50 void notifyService(); 52 void notifyService();
51 53
52 device::mojom::blink::WakeLockServicePtr m_service; 54 device::mojom::blink::WakeLockServicePtr m_service;
53 bool m_keepAwake; 55 bool m_keepAwake;
54 }; 56 };
55 57
56 } // namespace blink 58 } // namespace blink
57 59
58 #endif // ScreenWakeLock_h 60 #endif // ScreenWakeLock_h
OLDNEW
« no previous file with comments | « third_party/WebKit/Source/modules/vr/VRDisplay.cpp ('k') | third_party/WebKit/Source/modules/wake_lock/ScreenWakeLock.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698