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

Side by Side Diff: Source/modules/device_orientation/DeviceOrientationInspectorAgent.h

Issue 209333008: [DevTools] Support device orientation override on device with sensors. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Rebaselined test Created 6 years, 9 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 2014 The Chromium Authors. All rights reserved. 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 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 DeviceOrientationInspectorAgent_h 5 #ifndef DeviceOrientationInspectorAgent_h
6 #define DeviceOrientationInspectorAgent_h 6 #define DeviceOrientationInspectorAgent_h
7 7
8 #include "core/inspector/InspectorBaseAgent.h" 8 #include "core/inspector/InspectorBaseAgent.h"
9 #include "wtf/text/WTFString.h" 9 #include "wtf/text/WTFString.h"
10 10
11 namespace WebCore { 11 namespace WebCore {
12 12
13 class DeviceOrientationController;
13 class Page; 14 class Page;
14 15
15 typedef String ErrorString; 16 typedef String ErrorString;
16 17
17 class DeviceOrientationInspectorAgent FINAL : public InspectorBaseAgent<DeviceOr ientationInspectorAgent>, public InspectorBackendDispatcher::DeviceOrientationCo mmandHandler { 18 class DeviceOrientationInspectorAgent FINAL : public InspectorBaseAgent<DeviceOr ientationInspectorAgent>, public InspectorBackendDispatcher::DeviceOrientationCo mmandHandler {
18 WTF_MAKE_NONCOPYABLE(DeviceOrientationInspectorAgent); 19 WTF_MAKE_NONCOPYABLE(DeviceOrientationInspectorAgent);
19 public: 20 public:
20 static void provideTo(Page&); 21 static void provideTo(Page&);
21 22
22 virtual ~DeviceOrientationInspectorAgent(); 23 virtual ~DeviceOrientationInspectorAgent();
23 24
24 // Protocol methods. 25 // Protocol methods.
25 virtual void setDeviceOrientationOverride(ErrorString*, double, double, doub le) OVERRIDE; 26 virtual void setDeviceOrientationOverride(ErrorString*, double, double, doub le) OVERRIDE;
26 virtual void clearDeviceOrientationOverride(ErrorString*) OVERRIDE; 27 virtual void clearDeviceOrientationOverride(ErrorString*) OVERRIDE;
27 28
29 // Inspector Controller API.
30 virtual void clearFrontend() OVERRIDE;
31 virtual void restore() OVERRIDE;
32 virtual void didCommitLoadForMainFrame() OVERRIDE;
33
28 private: 34 private:
29 explicit DeviceOrientationInspectorAgent(Page&); 35 explicit DeviceOrientationInspectorAgent(Page&);
36 DeviceOrientationController& controller();
30 Page& m_page; 37 Page& m_page;
31 }; 38 };
32 39
33 } // namespace WebCore 40 } // namespace WebCore
34 41
35 42
36 #endif // !defined(DeviceOrientationInspectorAgent_h) 43 #endif // !defined(DeviceOrientationInspectorAgent_h)
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698