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

Side by Side Diff: Source/modules/screen_orientation/ScreenOrientationDispatcher.h

Issue 169403006: Screen Orientation API: screen.orientation & orientationchange event (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Take feedback into consideration Created 6 years, 10 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 | Annotate | Revision Log
OLDNEW
(Empty)
1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 #ifndef ScreenOrientationDispatcher_h
6 #define ScreenOrientationDispatcher_h
7
8 #include "public/platform/WebScreenOrientationListener.h"
9 #include "wtf/Vector.h"
10
11 namespace WebCore {
12
13 class ScreenOrientationController;
14
15 class ScreenOrientationDispatcher FINAL : public blink::WebScreenOrientationList ener {
16 public:
17 static ScreenOrientationDispatcher& instance();
18
19 void addController(ScreenOrientationController*);
20 void removeController(ScreenOrientationController*);
21
22 private:
23 ScreenOrientationDispatcher();
24
25 void purgeControllers();
26 void startListening();
27 void stopListening();
28
29 // WebScreenOrientationListener API.
30 virtual void didChangeScreenOrientation(blink::WebScreenOrientation) OVERRID E;
31
32 Vector<ScreenOrientationController*> m_controllers;
33 bool m_needsPurge;
34 bool m_isDispatching;
35 };
36
37 } // namespace WebCore
38
39 #endif // ScreenOrientationDispatcher_h
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698