Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(398)

Side by Side Diff: chrome/browser/renderer_host/render_view_host.cc

Issue 147246: Linux: middle-click to navigate (Closed)
Patch Set: ... Created 11 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 // Copyright (c) 2009 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2009 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/renderer_host/render_view_host.h" 5 #include "chrome/browser/renderer_host/render_view_host.h"
6 6
7 #include <string> 7 #include <string>
8 #include <vector> 8 #include <vector>
9 9
10 #include "app/resource_bundle.h" 10 #include "app/resource_bundle.h"
(...skipping 29 matching lines...) Expand all
40 // TODO(port): accessibility not yet implemented. See http://crbug.com/8288. 40 // TODO(port): accessibility not yet implemented. See http://crbug.com/8288.
41 #include "chrome/browser/browser_accessibility_manager.h" 41 #include "chrome/browser/browser_accessibility_manager.h"
42 #endif 42 #endif
43 43
44 using base::TimeDelta; 44 using base::TimeDelta;
45 using webkit_glue::AutofillForm; 45 using webkit_glue::AutofillForm;
46 using webkit_glue::PasswordFormDomManager; 46 using webkit_glue::PasswordFormDomManager;
47 using WebKit::WebConsoleMessage; 47 using WebKit::WebConsoleMessage;
48 using WebKit::WebFindOptions; 48 using WebKit::WebFindOptions;
49 using WebKit::WebInputEvent; 49 using WebKit::WebInputEvent;
50 using WebKit::WebMouseEvent;
50 51
51 namespace { 52 namespace {
52 53
53 void FilterURL(ChildProcessSecurityPolicy* policy, int renderer_id, GURL* url) { 54 void FilterURL(ChildProcessSecurityPolicy* policy, int renderer_id, GURL* url) {
54 if (!url->is_valid()) 55 if (!url->is_valid())
55 return; // We don't need to block invalid URLs. 56 return; // We don't need to block invalid URLs.
56 57
57 if (url->SchemeIs(chrome::kAboutScheme)) { 58 if (url->SchemeIs(chrome::kAboutScheme)) {
58 // The renderer treats all URLs in the about: scheme as being about:blank. 59 // The renderer treats all URLs in the about: scheme as being about:blank.
59 // Canonicalize about: URLs to about:blank. 60 // Canonicalize about: URLs to about:blank.
(...skipping 1156 matching lines...) Expand 10 before | Expand all | Expand 10 after
1216 // the renderer just send us the ones we care abount, or maybe the view 1217 // the renderer just send us the ones we care abount, or maybe the view
1217 // should be able to decide which ones it wants or not? 1218 // should be able to decide which ones it wants or not?
1218 if ((event.type == WebInputEvent::RawKeyDown) || 1219 if ((event.type == WebInputEvent::RawKeyDown) ||
1219 (event.type == WebInputEvent::KeyDown) || 1220 (event.type == WebInputEvent::KeyDown) ||
1220 (event.type == WebInputEvent::Char)) { 1221 (event.type == WebInputEvent::Char)) {
1221 view->HandleKeyboardEvent(event); 1222 view->HandleKeyboardEvent(event);
1222 } 1223 }
1223 } 1224 }
1224 } 1225 }
1225 1226
1227 void RenderViewHost::UnhandledMouseButtonEvent(
1228 const WebKit::WebMouseEvent* event) {
1229 RenderViewHostDelegate::View* view = delegate_->GetViewDelegate();
1230 if (view)
1231 view->HandleMouseButtonEvent(event);
1232 }
1233
1226 void RenderViewHost::OnUserGesture() { 1234 void RenderViewHost::OnUserGesture() {
1227 delegate_->OnUserGesture(); 1235 delegate_->OnUserGesture();
1228 } 1236 }
1229 1237
1230 void RenderViewHost::OnMissingPluginStatus(int status) { 1238 void RenderViewHost::OnMissingPluginStatus(int status) {
1231 delegate_->OnMissingPluginStatus(status); 1239 delegate_->OnMissingPluginStatus(status);
1232 } 1240 }
1233 1241
1234 void RenderViewHost::UpdateBackForwardListCount() { 1242 void RenderViewHost::UpdateBackForwardListCount() {
1235 int back_list_count = 0, forward_list_count = 0; 1243 int back_list_count = 0, forward_list_count = 0;
(...skipping 156 matching lines...) Expand 10 before | Expand all | Expand 10 after
1392 BrowserAccessibilityManager::GetInstance()-> 1400 BrowserAccessibilityManager::GetInstance()->
1393 ChangeAccessibilityFocus(acc_obj_id, process()->pid(), routing_id()); 1401 ChangeAccessibilityFocus(acc_obj_id, process()->pid(), routing_id());
1394 #else 1402 #else
1395 // TODO(port): accessibility not yet implemented. See http://crbug.com/8288. 1403 // TODO(port): accessibility not yet implemented. See http://crbug.com/8288.
1396 #endif 1404 #endif
1397 } 1405 }
1398 1406
1399 void RenderViewHost::OnCSSInserted() { 1407 void RenderViewHost::OnCSSInserted() {
1400 delegate_->DidInsertCSS(); 1408 delegate_->DidInsertCSS();
1401 } 1409 }
OLDNEW
« no previous file with comments | « chrome/browser/renderer_host/render_view_host.h ('k') | chrome/browser/renderer_host/render_view_host_delegate.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698