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

Side by Side Diff: chrome/browser/ui/gtk/constrained_web_dialog_delegate_gtk.cc

Issue 10545115: TabContentsWrapper -> TabContents, part 41. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 years, 6 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 | Annotate | Revision Log
OLDNEW
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 "chrome/browser/ui/webui/constrained_web_dialog_delegate_base.h" 5 #include "chrome/browser/ui/webui/constrained_web_dialog_delegate_base.h"
6 6
7 #include "chrome/browser/ui/gtk/constrained_window_gtk.h" 7 #include "chrome/browser/ui/gtk/constrained_window_gtk.h"
8 #include "chrome/browser/ui/gtk/tab_contents_container_gtk.h" 8 #include "chrome/browser/ui/gtk/tab_contents_container_gtk.h"
9 #include "chrome/browser/ui/tab_contents/tab_contents_wrapper.h" 9 #include "chrome/browser/ui/tab_contents/tab_contents.h"
10 #include "content/public/browser/notification_source.h" 10 #include "content/public/browser/notification_source.h"
11 #include "content/public/browser/render_view_host.h" 11 #include "content/public/browser/render_view_host.h"
12 #include "content/public/browser/web_contents.h" 12 #include "content/public/browser/web_contents.h"
13 #include "ui/base/gtk/gtk_hig_constants.h" 13 #include "ui/base/gtk/gtk_hig_constants.h"
14 #include "ui/gfx/size.h" 14 #include "ui/gfx/size.h"
15 #include "ui/web_dialogs/web_dialog_delegate.h" 15 #include "ui/web_dialogs/web_dialog_delegate.h"
16 #include "ui/web_dialogs/web_dialog_ui.h" 16 #include "ui/web_dialogs/web_dialog_ui.h"
17 17
18 using content::WebContents; 18 using content::WebContents;
19 using ui::ConstrainedWebDialogDelegate; 19 using ui::ConstrainedWebDialogDelegate;
(...skipping 24 matching lines...) Expand all
44 } 44 }
45 virtual void OnDialogCloseFromWebUI() OVERRIDE { 45 virtual void OnDialogCloseFromWebUI() OVERRIDE {
46 return impl_->OnDialogCloseFromWebUI(); 46 return impl_->OnDialogCloseFromWebUI();
47 } 47 }
48 virtual void ReleaseTabContentsOnDialogClose() OVERRIDE { 48 virtual void ReleaseTabContentsOnDialogClose() OVERRIDE {
49 return impl_->ReleaseTabContentsOnDialogClose(); 49 return impl_->ReleaseTabContentsOnDialogClose();
50 } 50 }
51 virtual ConstrainedWindow* window() OVERRIDE { 51 virtual ConstrainedWindow* window() OVERRIDE {
52 return impl_->window(); 52 return impl_->window();
53 } 53 }
54 virtual TabContentsWrapper* tab() OVERRIDE { 54 virtual TabContents* tab() OVERRIDE {
55 return impl_->tab(); 55 return impl_->tab();
56 } 56 }
57 57
58 // ConstrainedWindowGtkDelegate interface 58 // ConstrainedWindowGtkDelegate interface
59 virtual GtkWidget* GetWidgetRoot() OVERRIDE { 59 virtual GtkWidget* GetWidgetRoot() OVERRIDE {
60 return tab_contents_container_.widget(); 60 return tab_contents_container_.widget();
61 } 61 }
62 virtual GtkWidget* GetFocusWidget() OVERRIDE { 62 virtual GtkWidget* GetFocusWidget() OVERRIDE {
63 return tab()->web_contents()->GetContentNativeView(); 63 return tab()->web_contents()->GetContentNativeView();
64 } 64 }
(...skipping 29 matching lines...) Expand all
94 dialog_size.width(), 94 dialog_size.width(),
95 dialog_size.height()); 95 dialog_size.height());
96 96
97 gtk_widget_show_all(GetWidgetRoot()); 97 gtk_widget_show_all(GetWidgetRoot());
98 } 98 }
99 99
100 ConstrainedWebDialogDelegate* ui::CreateConstrainedWebDialog( 100 ConstrainedWebDialogDelegate* ui::CreateConstrainedWebDialog(
101 Profile* profile, 101 Profile* profile,
102 WebDialogDelegate* delegate, 102 WebDialogDelegate* delegate,
103 WebDialogWebContentsDelegate* tab_delegate, 103 WebDialogWebContentsDelegate* tab_delegate,
104 TabContentsWrapper* overshadowed) { 104 TabContents* overshadowed) {
105 ConstrainedWebDialogDelegateGtk* constrained_delegate = 105 ConstrainedWebDialogDelegateGtk* constrained_delegate =
106 new ConstrainedWebDialogDelegateGtk(profile, delegate, tab_delegate); 106 new ConstrainedWebDialogDelegateGtk(profile, delegate, tab_delegate);
107 ConstrainedWindow* constrained_window = 107 ConstrainedWindow* constrained_window =
108 new ConstrainedWindowGtk(overshadowed, constrained_delegate); 108 new ConstrainedWindowGtk(overshadowed, constrained_delegate);
109 constrained_delegate->set_window(constrained_window); 109 constrained_delegate->set_window(constrained_window);
110 return constrained_delegate; 110 return constrained_delegate;
111 } 111 }
OLDNEW
« no previous file with comments | « chrome/browser/ui/gtk/collected_cookies_gtk.cc ('k') | chrome/browser/ui/gtk/constrained_window_gtk.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698