| OLD | NEW |
| 1 // Copyright (c) 2006-2008 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2006-2008 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/tab_contents/web_contents_view_win.h" | 5 #include "chrome/browser/tab_contents/web_contents_view_win.h" |
| 6 | 6 |
| 7 #include <windows.h> | 7 #include <windows.h> |
| 8 | 8 |
| 9 #include "chrome/browser/bookmarks/bookmark_drag_data.h" | 9 #include "chrome/browser/bookmarks/bookmark_drag_data.h" |
| 10 #include "chrome/browser/browser.h" // TODO(beng): this dependency is awful. | 10 #include "chrome/browser/browser.h" // TODO(beng): this dependency is awful. |
| (...skipping 202 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 213 } | 213 } |
| 214 | 214 |
| 215 void WebContentsViewWin::OpenDeveloperTools() { | 215 void WebContentsViewWin::OpenDeveloperTools() { |
| 216 if (!dev_tools_window_.get()) | 216 if (!dev_tools_window_.get()) |
| 217 dev_tools_window_.reset(new DevToolsWindow); | 217 dev_tools_window_.reset(new DevToolsWindow); |
| 218 | 218 |
| 219 RenderViewHost* host = web_contents_->render_view_host(); | 219 RenderViewHost* host = web_contents_->render_view_host(); |
| 220 if (!host) | 220 if (!host) |
| 221 return; | 221 return; |
| 222 | 222 |
| 223 dev_tools_window_->Show(host->process()->host_id(), host->routing_id()); | 223 dev_tools_window_->Show(host->process()->pid(), host->routing_id()); |
| 224 } | 224 } |
| 225 | 225 |
| 226 void WebContentsViewWin::ForwardMessageToDevToolsClient( | 226 void WebContentsViewWin::ForwardMessageToDevToolsClient( |
| 227 const IPC::Message& message) { | 227 const IPC::Message& message) { |
| 228 if (!dev_tools_window_.get()) { | 228 if (!dev_tools_window_.get()) { |
| 229 NOTREACHED() << "Developer tools window is not open."; | 229 NOTREACHED() << "Developer tools window is not open."; |
| 230 return; | 230 return; |
| 231 } | 231 } |
| 232 dev_tools_window_->SendDevToolsClientMessage(message); | 232 dev_tools_window_->SendDevToolsClientMessage(message); |
| 233 } | 233 } |
| (...skipping 385 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 619 } | 619 } |
| 620 return false; | 620 return false; |
| 621 } | 621 } |
| 622 | 622 |
| 623 void WebContentsViewWin::WheelZoom(int distance) { | 623 void WebContentsViewWin::WheelZoom(int distance) { |
| 624 if (web_contents_->delegate()) { | 624 if (web_contents_->delegate()) { |
| 625 bool zoom_in = distance > 0; | 625 bool zoom_in = distance > 0; |
| 626 web_contents_->delegate()->ContentsZoomChange(zoom_in); | 626 web_contents_->delegate()->ContentsZoomChange(zoom_in); |
| 627 } | 627 } |
| 628 } | 628 } |
| OLD | NEW |