| OLD | NEW |
| 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/views/tab_contents/native_tab_contents_container_gtk.h" | 5 #include "chrome/browser/views/tab_contents/native_tab_contents_container_gtk.h" |
| 6 | 6 |
| 7 #include "chrome/browser/renderer_host/render_widget_host_view.h" | 7 #include "chrome/browser/renderer_host/render_widget_host_view.h" |
| 8 #include "chrome/browser/tab_contents/interstitial_page.h" | 8 #include "chrome/browser/tab_contents/interstitial_page.h" |
| 9 #include "chrome/browser/tab_contents/tab_contents.h" | 9 #include "chrome/browser/tab_contents/tab_contents.h" |
| 10 #include "chrome/browser/view_ids.h" |
| 10 #include "chrome/browser/views/tab_contents/tab_contents_container.h" | 11 #include "chrome/browser/views/tab_contents/tab_contents_container.h" |
| 11 #include "views/focus/focus_manager.h" | 12 #include "views/focus/focus_manager.h" |
| 12 #include "views/widget/root_view.h" | 13 #include "views/widget/root_view.h" |
| 13 #include "views/widget/widget.h" | 14 #include "views/widget/widget.h" |
| 14 | 15 |
| 15 //////////////////////////////////////////////////////////////////////////////// | 16 //////////////////////////////////////////////////////////////////////////////// |
| 16 // NativeTabContentsContainerGtk, public: | 17 // NativeTabContentsContainerGtk, public: |
| 17 | 18 |
| 18 NativeTabContentsContainerGtk::NativeTabContentsContainerGtk( | 19 NativeTabContentsContainerGtk::NativeTabContentsContainerGtk( |
| 19 TabContentsContainer* container) | 20 TabContentsContainer* container) |
| 20 : container_(container), | 21 : container_(container), |
| 21 focus_callback_id_(0) { | 22 focus_callback_id_(0) { |
| 23 SetID(VIEW_ID_TAB_CONTAINER_FOCUS_VIEW); |
| 22 } | 24 } |
| 23 | 25 |
| 24 NativeTabContentsContainerGtk::~NativeTabContentsContainerGtk() { | 26 NativeTabContentsContainerGtk::~NativeTabContentsContainerGtk() { |
| 25 } | 27 } |
| 26 | 28 |
| 27 //////////////////////////////////////////////////////////////////////////////// | 29 //////////////////////////////////////////////////////////////////////////////// |
| 28 // NativeTabContentsContainerGtk, NativeTabContentsContainer overrides: | 30 // NativeTabContentsContainerGtk, NativeTabContentsContainer overrides: |
| 29 | 31 |
| 30 void NativeTabContentsContainerGtk::AttachContents(TabContents* contents) { | 32 void NativeTabContentsContainerGtk::AttachContents(TabContents* contents) { |
| 31 Attach(contents->GetNativeView()); | 33 Attach(contents->GetNativeView()); |
| (...skipping 112 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 144 } | 146 } |
| 145 | 147 |
| 146 //////////////////////////////////////////////////////////////////////////////// | 148 //////////////////////////////////////////////////////////////////////////////// |
| 147 // NativeTabContentsContainer, public: | 149 // NativeTabContentsContainer, public: |
| 148 | 150 |
| 149 // static | 151 // static |
| 150 NativeTabContentsContainer* NativeTabContentsContainer::CreateNativeContainer( | 152 NativeTabContentsContainer* NativeTabContentsContainer::CreateNativeContainer( |
| 151 TabContentsContainer* container) { | 153 TabContentsContainer* container) { |
| 152 return new NativeTabContentsContainerGtk(container); | 154 return new NativeTabContentsContainerGtk(container); |
| 153 } | 155 } |
| OLD | NEW |