OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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/browser/devtools/devtools_frontend_host.h" | 5 #include "content/browser/devtools/devtools_frontend_host.h" |
6 | 6 |
7 #include "content/browser/devtools/devtools_manager_impl.h" | 7 #include "content/browser/devtools/devtools_manager_impl.h" |
8 #include "content/browser/renderer_host/render_view_host_impl.h" | 8 #include "content/browser/renderer_host/render_view_host_impl.h" |
9 #include "content/browser/web_contents/web_contents_impl.h" | 9 #include "content/browser/web_contents/web_contents_impl.h" |
10 #include "content/common/devtools_messages.h" | 10 #include "content/common/devtools_messages.h" |
(...skipping 52 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
63 IPC_MESSAGE_HANDLER(DevToolsAgentMsg_DispatchOnInspectorBackend, | 63 IPC_MESSAGE_HANDLER(DevToolsAgentMsg_DispatchOnInspectorBackend, |
64 OnDispatchOnInspectorBackend) | 64 OnDispatchOnInspectorBackend) |
65 IPC_MESSAGE_HANDLER(DevToolsHostMsg_ActivateWindow, OnActivateWindow) | 65 IPC_MESSAGE_HANDLER(DevToolsHostMsg_ActivateWindow, OnActivateWindow) |
66 IPC_MESSAGE_HANDLER(DevToolsHostMsg_CloseWindow, OnCloseWindow) | 66 IPC_MESSAGE_HANDLER(DevToolsHostMsg_CloseWindow, OnCloseWindow) |
67 IPC_MESSAGE_HANDLER(DevToolsHostMsg_MoveWindow, OnMoveWindow) | 67 IPC_MESSAGE_HANDLER(DevToolsHostMsg_MoveWindow, OnMoveWindow) |
68 IPC_MESSAGE_HANDLER(DevToolsHostMsg_RequestSetDockSide, | 68 IPC_MESSAGE_HANDLER(DevToolsHostMsg_RequestSetDockSide, |
69 OnRequestSetDockSide) | 69 OnRequestSetDockSide) |
70 IPC_MESSAGE_HANDLER(DevToolsHostMsg_OpenInNewTab, OnOpenInNewTab) | 70 IPC_MESSAGE_HANDLER(DevToolsHostMsg_OpenInNewTab, OnOpenInNewTab) |
71 IPC_MESSAGE_HANDLER(DevToolsHostMsg_Save, OnSave) | 71 IPC_MESSAGE_HANDLER(DevToolsHostMsg_Save, OnSave) |
72 IPC_MESSAGE_HANDLER(DevToolsHostMsg_Append, OnAppend) | 72 IPC_MESSAGE_HANDLER(DevToolsHostMsg_Append, OnAppend) |
| 73 IPC_MESSAGE_HANDLER(DevToolsHostMsg_RequestFileSystems, |
| 74 OnRequestFileSystems) |
| 75 IPC_MESSAGE_HANDLER(DevToolsHostMsg_AddFileSystem, OnAddFileSystem) |
| 76 IPC_MESSAGE_HANDLER(DevToolsHostMsg_RemoveFileSystem, OnRemoveFileSystem) |
73 IPC_MESSAGE_UNHANDLED(handled = false) | 77 IPC_MESSAGE_UNHANDLED(handled = false) |
74 IPC_END_MESSAGE_MAP() | 78 IPC_END_MESSAGE_MAP() |
75 return handled; | 79 return handled; |
76 } | 80 } |
77 | 81 |
78 void DevToolsFrontendHost::OnDispatchOnInspectorBackend( | 82 void DevToolsFrontendHost::OnDispatchOnInspectorBackend( |
79 const std::string& message) { | 83 const std::string& message) { |
80 DevToolsManagerImpl::GetInstance()->DispatchOnInspectorBackend(this, message); | 84 DevToolsManagerImpl::GetInstance()->DispatchOnInspectorBackend(this, message); |
81 // delegate_->DispatchOnInspectorBackend(message); | 85 // delegate_->DispatchOnInspectorBackend(message); |
82 } | 86 } |
(...skipping 20 matching lines...) Expand all Loading... |
103 bool save_as) { | 107 bool save_as) { |
104 delegate_->SaveToFile(url, content, save_as); | 108 delegate_->SaveToFile(url, content, save_as); |
105 } | 109 } |
106 | 110 |
107 void DevToolsFrontendHost::OnAppend( | 111 void DevToolsFrontendHost::OnAppend( |
108 const std::string& url, | 112 const std::string& url, |
109 const std::string& content) { | 113 const std::string& content) { |
110 delegate_->AppendToFile(url, content); | 114 delegate_->AppendToFile(url, content); |
111 } | 115 } |
112 | 116 |
| 117 void DevToolsFrontendHost::OnRequestFileSystems() { |
| 118 delegate_->RequestFileSystems(); |
| 119 } |
| 120 |
| 121 void DevToolsFrontendHost::OnAddFileSystem() { |
| 122 delegate_->AddFileSystem(); |
| 123 } |
| 124 |
| 125 void DevToolsFrontendHost::OnRemoveFileSystem( |
| 126 const std::string& file_system_path) { |
| 127 delegate_->RemoveFileSystem(file_system_path); |
| 128 } |
| 129 |
113 void DevToolsFrontendHost::OnRequestSetDockSide(const std::string& side) { | 130 void DevToolsFrontendHost::OnRequestSetDockSide(const std::string& side) { |
114 delegate_->SetDockSide(side); | 131 delegate_->SetDockSide(side); |
115 } | 132 } |
116 | 133 |
117 } // namespace content | 134 } // namespace content |
OLD | NEW |