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

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

Issue 10703061: chrome/browser/ui: Put browser_dialogs.h into chrome namespace. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 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 | 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/gtk/web_dialog_gtk.h" 5 #include "chrome/browser/ui/gtk/web_dialog_gtk.h"
6 6
7 #include <gtk/gtk.h> 7 #include <gtk/gtk.h>
8 8
9 #include "base/property_bag.h" 9 #include "base/property_bag.h"
10 #include "base/utf_string_conversions.h" 10 #include "base/utf_string_conversions.h"
11 #include "chrome/browser/profiles/profile.h" 11 #include "chrome/browser/profiles/profile.h"
12 #include "chrome/browser/ui/browser_dialogs.h" 12 #include "chrome/browser/ui/browser_dialogs.h"
13 #include "chrome/browser/ui/gtk/gtk_util.h" 13 #include "chrome/browser/ui/gtk/gtk_util.h"
14 #include "chrome/browser/ui/gtk/tab_contents_container_gtk.h" 14 #include "chrome/browser/ui/gtk/tab_contents_container_gtk.h"
15 #include "chrome/browser/ui/tab_contents/tab_contents.h" 15 #include "chrome/browser/ui/tab_contents/tab_contents.h"
16 #include "content/public/browser/native_web_keyboard_event.h" 16 #include "content/public/browser/native_web_keyboard_event.h"
17 #include "content/public/browser/web_contents.h" 17 #include "content/public/browser/web_contents.h"
18 #include "ui/web_dialogs/web_dialog_ui.h" 18 #include "ui/web_dialogs/web_dialog_ui.h"
19 19
20 using content::NativeWebKeyboardEvent; 20 using content::NativeWebKeyboardEvent;
21 using content::WebContents; 21 using content::WebContents;
22 using content::WebUIMessageHandler; 22 using content::WebUIMessageHandler;
23 using ui::WebDialogDelegate; 23 using ui::WebDialogDelegate;
24 using ui::WebDialogUI; 24 using ui::WebDialogUI;
25 25
26 namespace browser { 26 namespace chrome {
27 27
28 gfx::NativeWindow ShowWebDialog(gfx::NativeWindow parent, 28 gfx::NativeWindow ShowWebDialog(gfx::NativeWindow parent,
29 content::BrowserContext* context, 29 content::BrowserContext* context,
30 WebDialogDelegate* delegate) { 30 WebDialogDelegate* delegate) {
31 WebDialogGtk* web_dialog = new WebDialogGtk(context, delegate, parent); 31 WebDialogGtk* web_dialog = new WebDialogGtk(context, delegate, parent);
32 return web_dialog->InitDialog(); 32 return web_dialog->InitDialog();
33 } 33 }
34 34
35 } // namespace browser 35 } // namespace chrome
36 36
37 namespace { 37 namespace {
38 38
39 void SetDialogStyle() { 39 void SetDialogStyle() {
40 static bool style_was_set = false; 40 static bool style_was_set = false;
41 41
42 if (style_was_set) 42 if (style_was_set)
43 return; 43 return;
44 style_was_set = true; 44 style_was_set = true;
45 45
(...skipping 208 matching lines...) Expand 10 before | Expand all | Expand 10 after
254 } 254 }
255 255
256 gtk_widget_show_all(dialog_); 256 gtk_widget_show_all(dialog_);
257 257
258 return GTK_WINDOW(dialog_); 258 return GTK_WINDOW(dialog_);
259 } 259 }
260 260
261 void WebDialogGtk::OnResponse(GtkWidget* dialog, int response_id) { 261 void WebDialogGtk::OnResponse(GtkWidget* dialog, int response_id) {
262 OnDialogClosed(std::string()); 262 OnDialogClosed(std::string());
263 } 263 }
OLDNEW
« no previous file with comments | « chrome/browser/ui/gtk/tab_modal_confirm_dialog_gtk.cc ('k') | chrome/browser/ui/views/about_ipc_dialog.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698