| OLD | NEW |
| 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 #include "modules/device_orientation/DeviceOrientationInspectorAgent.h" | 5 #include "modules/device_orientation/DeviceOrientationInspectorAgent.h" |
| 6 | 6 |
| 7 #include "core/frame/LocalFrame.h" | 7 #include "core/frame/LocalFrame.h" |
| 8 #include "core/inspector/InspectedFrames.h" | 8 #include "core/inspector/InspectedFrames.h" |
| 9 #include "modules/device_orientation/DeviceOrientationController.h" | 9 #include "modules/device_orientation/DeviceOrientationController.h" |
| 10 #include "modules/device_orientation/DeviceOrientationData.h" | 10 #include "modules/device_orientation/DeviceOrientationData.h" |
| 11 #include "wtf/Assertions.h" | 11 #include "platform/wtf/Assertions.h" |
| 12 | 12 |
| 13 namespace blink { | 13 namespace blink { |
| 14 | 14 |
| 15 using protocol::Response; | 15 using protocol::Response; |
| 16 | 16 |
| 17 namespace DeviceOrientationInspectorAgentState { | 17 namespace DeviceOrientationInspectorAgentState { |
| 18 static const char kAlpha[] = "alpha"; | 18 static const char kAlpha[] = "alpha"; |
| 19 static const char kBeta[] = "beta"; | 19 static const char kBeta[] = "beta"; |
| 20 static const char kGamma[] = "gamma"; | 20 static const char kGamma[] = "gamma"; |
| 21 static const char kOverrideEnabled[] = "overrideEnabled"; | 21 static const char kOverrideEnabled[] = "overrideEnabled"; |
| (...skipping 66 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 88 void DeviceOrientationInspectorAgent::DidCommitLoadForLocalFrame( | 88 void DeviceOrientationInspectorAgent::DidCommitLoadForLocalFrame( |
| 89 LocalFrame* frame) { | 89 LocalFrame* frame) { |
| 90 if (frame == inspected_frames_->Root()) { | 90 if (frame == inspected_frames_->Root()) { |
| 91 // New document in main frame - apply override there. | 91 // New document in main frame - apply override there. |
| 92 // No need to cleanup previous one, as it's already gone. | 92 // No need to cleanup previous one, as it's already gone. |
| 93 Restore(); | 93 Restore(); |
| 94 } | 94 } |
| 95 } | 95 } |
| 96 | 96 |
| 97 } // namespace blink | 97 } // namespace blink |
| OLD | NEW |