| 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 "content/renderer/screen_orientation/screen_orientation_dispatcher.h" | 5 #include "content/renderer/screen_orientation/screen_orientation_dispatcher.h" |
| 6 | 6 |
| 7 #include "content/public/common/associated_interface_provider.h" | 7 #include "content/public/common/associated_interface_provider.h" |
| 8 #include "content/public/renderer/render_frame.h" | 8 #include "content/public/renderer/render_frame.h" |
| 9 | 9 |
| 10 namespace content { | 10 namespace content { |
| 11 | 11 |
| 12 using ::blink::mojom::ScreenOrientationLockResult; | 12 using device::mojom::ScreenOrientationLockResult; |
| 13 | 13 |
| 14 ScreenOrientationDispatcher::ScreenOrientationDispatcher( | 14 ScreenOrientationDispatcher::ScreenOrientationDispatcher( |
| 15 RenderFrame* render_frame) | 15 RenderFrame* render_frame) |
| 16 : RenderFrameObserver(render_frame) { | 16 : RenderFrameObserver(render_frame) { |
| 17 } | 17 } |
| 18 | 18 |
| 19 ScreenOrientationDispatcher::~ScreenOrientationDispatcher() { | 19 ScreenOrientationDispatcher::~ScreenOrientationDispatcher() { |
| 20 } | 20 } |
| 21 | 21 |
| 22 void ScreenOrientationDispatcher::OnDestruct() { | 22 void ScreenOrientationDispatcher::OnDestruct() { |
| (...skipping 68 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 91 | 91 |
| 92 int ScreenOrientationDispatcher::GetRequestIdForTests() { | 92 int ScreenOrientationDispatcher::GetRequestIdForTests() { |
| 93 if (pending_callbacks_.IsEmpty()) | 93 if (pending_callbacks_.IsEmpty()) |
| 94 return -1; | 94 return -1; |
| 95 CallbackMap::Iterator<blink::WebLockOrientationCallback> iterator( | 95 CallbackMap::Iterator<blink::WebLockOrientationCallback> iterator( |
| 96 &pending_callbacks_); | 96 &pending_callbacks_); |
| 97 return iterator.GetCurrentKey(); | 97 return iterator.GetCurrentKey(); |
| 98 } | 98 } |
| 99 | 99 |
| 100 } // namespace content | 100 } // namespace content |
| OLD | NEW |