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

Side by Side Diff: chrome/browser/ui/views/tab_contents/native_tab_contents_container_gtk.cc

Issue 8949061: Move a bunch of methods from TabContents into the WebContents interface. This change either moves... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 9 years 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 | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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/ui/views/tab_contents/native_tab_contents_container_gtk .h" 5 #include "chrome/browser/ui/views/tab_contents/native_tab_contents_container_gtk .h"
6 6
7 #include "chrome/browser/ui/view_ids.h" 7 #include "chrome/browser/ui/view_ids.h"
8 #include "chrome/browser/ui/views/tab_contents/tab_contents_container.h" 8 #include "chrome/browser/ui/views/tab_contents/tab_contents_container.h"
9 #include "chrome/browser/ui/views/tab_contents/tab_contents_view_views.h" 9 #include "chrome/browser/ui/views/tab_contents/tab_contents_view_views.h"
10 #include "content/browser/renderer_host/render_widget_host_view.h" 10 #include "content/browser/renderer_host/render_widget_host_view.h"
(...skipping 72 matching lines...) Expand 10 before | Expand all | Expand 10 after
83 // NativeTabContentsContainerGtk, views::View overrides: 83 // NativeTabContentsContainerGtk, views::View overrides:
84 84
85 bool NativeTabContentsContainerGtk::SkipDefaultKeyEventProcessing( 85 bool NativeTabContentsContainerGtk::SkipDefaultKeyEventProcessing(
86 const views::KeyEvent& e) { 86 const views::KeyEvent& e) {
87 // Don't look-up accelerators or tab-traverse if we are showing a non-crashed 87 // Don't look-up accelerators or tab-traverse if we are showing a non-crashed
88 // TabContents. 88 // TabContents.
89 // We'll first give the page a chance to process the key events. If it does 89 // We'll first give the page a chance to process the key events. If it does
90 // not process them, they'll be returned to us and we'll treat them as 90 // not process them, they'll be returned to us and we'll treat them as
91 // accelerators then. 91 // accelerators then.
92 return container_->tab_contents() && 92 return container_->tab_contents() &&
93 !container_->tab_contents()->is_crashed(); 93 !container_->tab_contents()->IsCrashed();
94 } 94 }
95 95
96 views::FocusTraversable* NativeTabContentsContainerGtk::GetFocusTraversable() { 96 views::FocusTraversable* NativeTabContentsContainerGtk::GetFocusTraversable() {
97 return NULL; 97 return NULL;
98 } 98 }
99 99
100 bool NativeTabContentsContainerGtk::IsFocusable() const { 100 bool NativeTabContentsContainerGtk::IsFocusable() const {
101 // We need to be focusable when our contents is not a view hierarchy, as 101 // We need to be focusable when our contents is not a view hierarchy, as
102 // clicking on the contents needs to focus us. 102 // clicking on the contents needs to focus us.
103 return container_->tab_contents() != NULL; 103 return container_->tab_contents() != NULL;
(...skipping 39 matching lines...) Expand 10 before | Expand all | Expand 10 after
143 } 143 }
144 144
145 //////////////////////////////////////////////////////////////////////////////// 145 ////////////////////////////////////////////////////////////////////////////////
146 // NativeTabContentsContainer, public: 146 // NativeTabContentsContainer, public:
147 147
148 // static 148 // static
149 NativeTabContentsContainer* NativeTabContentsContainer::CreateNativeContainer( 149 NativeTabContentsContainer* NativeTabContentsContainer::CreateNativeContainer(
150 TabContentsContainer* container) { 150 TabContentsContainer* container) {
151 return new NativeTabContentsContainerGtk(container); 151 return new NativeTabContentsContainerGtk(container);
152 } 152 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698