| OLD | NEW |
| 1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2010 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 "chrome/browser/device_orientation/dispatcher_host.h" | 5 #include "chrome/browser/device_orientation/dispatcher_host.h" |
| 6 | 6 |
| 7 #include "base/scoped_ptr.h" | 7 #include "base/scoped_ptr.h" |
| 8 #include "chrome/browser/chrome_thread.h" | 8 #include "chrome/browser/chrome_thread.h" |
| 9 #include "chrome/browser/device_orientation/orientation.h" | 9 #include "chrome/browser/device_orientation/orientation.h" |
| 10 #include "chrome/browser/device_orientation/provider.h" | 10 #include "chrome/browser/device_orientation/provider.h" |
| 11 #include "chrome/browser/renderer_host/render_view_host.h" | 11 #include "chrome/browser/renderer_host/render_view_host.h" |
| 12 #include "chrome/browser/renderer_host/render_view_host_notification_task.h" | 12 #include "chrome/browser/renderer_host/render_view_host_notification_task.h" |
| 13 #include "chrome/common/render_messages.h" | 13 #include "chrome/common/render_messages.h" |
| 14 #include "chrome/common/render_messages_params.h" |
| 14 #include "ipc/ipc_message.h" | 15 #include "ipc/ipc_message.h" |
| 15 | 16 |
| 16 namespace device_orientation { | 17 namespace device_orientation { |
| 17 | 18 |
| 18 DispatcherHost::DispatcherHost(int process_id) | 19 DispatcherHost::DispatcherHost(int process_id) |
| 19 : process_id_(process_id), | 20 : process_id_(process_id), |
| 20 observers_map_(), | 21 observers_map_(), |
| 21 provider_(NULL) { | 22 provider_(NULL) { |
| 22 } | 23 } |
| 23 | 24 |
| (...skipping 78 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 102 render_view_id); | 103 render_view_id); |
| 103 } | 104 } |
| 104 | 105 |
| 105 void DispatcherHost::OnStopUpdating(int render_view_id) { | 106 void DispatcherHost::OnStopUpdating(int render_view_id) { |
| 106 DCHECK(ChromeThread::CurrentlyOn(ChromeThread::IO)); | 107 DCHECK(ChromeThread::CurrentlyOn(ChromeThread::IO)); |
| 107 | 108 |
| 108 observers_map_.erase(render_view_id); | 109 observers_map_.erase(render_view_id); |
| 109 } | 110 } |
| 110 | 111 |
| 111 } // namespace device_orientation | 112 } // namespace device_orientation |
| OLD | NEW |