OLD | NEW |
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/gtk/browser_window_gtk.h" | 5 #include "chrome/browser/ui/gtk/browser_window_gtk.h" |
6 | 6 |
7 #include <gdk/gdkkeysyms.h> | 7 #include <gdk/gdkkeysyms.h> |
8 | 8 |
9 #include <string> | 9 #include <string> |
10 | 10 |
(...skipping 43 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
54 #include "chrome/browser/ui/gtk/gtk_floating_container.h" | 54 #include "chrome/browser/ui/gtk/gtk_floating_container.h" |
55 #include "chrome/browser/ui/gtk/gtk_theme_provider.h" | 55 #include "chrome/browser/ui/gtk/gtk_theme_provider.h" |
56 #include "chrome/browser/ui/gtk/gtk_util.h" | 56 #include "chrome/browser/ui/gtk/gtk_util.h" |
57 #include "chrome/browser/ui/gtk/importer/import_dialog_gtk.h" | 57 #include "chrome/browser/ui/gtk/importer/import_dialog_gtk.h" |
58 #include "chrome/browser/ui/gtk/info_bubble_gtk.h" | 58 #include "chrome/browser/ui/gtk/info_bubble_gtk.h" |
59 #include "chrome/browser/ui/gtk/infobars/infobar_container_gtk.h" | 59 #include "chrome/browser/ui/gtk/infobars/infobar_container_gtk.h" |
60 #include "chrome/browser/ui/gtk/infobars/infobar_gtk.h" | 60 #include "chrome/browser/ui/gtk/infobars/infobar_gtk.h" |
61 #include "chrome/browser/ui/gtk/keyword_editor_view.h" | 61 #include "chrome/browser/ui/gtk/keyword_editor_view.h" |
62 #include "chrome/browser/ui/gtk/location_bar_view_gtk.h" | 62 #include "chrome/browser/ui/gtk/location_bar_view_gtk.h" |
63 #include "chrome/browser/ui/gtk/nine_box.h" | 63 #include "chrome/browser/ui/gtk/nine_box.h" |
64 #include "chrome/browser/ui/gtk/options/content_settings_window_gtk.h" | |
65 #include "chrome/browser/ui/gtk/reload_button_gtk.h" | 64 #include "chrome/browser/ui/gtk/reload_button_gtk.h" |
66 #include "chrome/browser/ui/gtk/repost_form_warning_gtk.h" | 65 #include "chrome/browser/ui/gtk/repost_form_warning_gtk.h" |
67 #include "chrome/browser/ui/gtk/status_bubble_gtk.h" | 66 #include "chrome/browser/ui/gtk/status_bubble_gtk.h" |
68 #include "chrome/browser/ui/gtk/tab_contents_container_gtk.h" | 67 #include "chrome/browser/ui/gtk/tab_contents_container_gtk.h" |
69 #include "chrome/browser/ui/gtk/tabs/tab_strip_gtk.h" | 68 #include "chrome/browser/ui/gtk/tabs/tab_strip_gtk.h" |
70 #include "chrome/browser/ui/gtk/task_manager_gtk.h" | 69 #include "chrome/browser/ui/gtk/task_manager_gtk.h" |
71 #include "chrome/browser/ui/gtk/theme_install_bubble_view_gtk.h" | 70 #include "chrome/browser/ui/gtk/theme_install_bubble_view_gtk.h" |
72 #include "chrome/browser/ui/gtk/update_recommended_dialog.h" | 71 #include "chrome/browser/ui/gtk/update_recommended_dialog.h" |
73 #include "chrome/browser/ui/omnibox/location_bar.h" | 72 #include "chrome/browser/ui/omnibox/location_bar.h" |
74 #include "chrome/browser/ui/tab_contents/tab_contents_wrapper.h" | 73 #include "chrome/browser/ui/tab_contents/tab_contents_wrapper.h" |
(...skipping 803 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
878 if (!download_shelf_.get()) | 877 if (!download_shelf_.get()) |
879 download_shelf_.reset(new DownloadShelfGtk(browser_.get(), | 878 download_shelf_.reset(new DownloadShelfGtk(browser_.get(), |
880 render_area_vbox_)); | 879 render_area_vbox_)); |
881 return download_shelf_.get(); | 880 return download_shelf_.get(); |
882 } | 881 } |
883 | 882 |
884 void BrowserWindowGtk::ShowRepostFormWarningDialog(TabContents* tab_contents) { | 883 void BrowserWindowGtk::ShowRepostFormWarningDialog(TabContents* tab_contents) { |
885 new RepostFormWarningGtk(GetNativeHandle(), tab_contents); | 884 new RepostFormWarningGtk(GetNativeHandle(), tab_contents); |
886 } | 885 } |
887 | 886 |
888 void BrowserWindowGtk::ShowContentSettingsWindow( | |
889 ContentSettingsType content_type, | |
890 Profile* profile) { | |
891 ContentSettingsWindowGtk::Show(GetNativeHandle(), content_type, profile); | |
892 } | |
893 | |
894 void BrowserWindowGtk::ShowCollectedCookiesDialog(TabContents* tab_contents) { | 887 void BrowserWindowGtk::ShowCollectedCookiesDialog(TabContents* tab_contents) { |
895 // Deletes itself on close. | 888 // Deletes itself on close. |
896 new CollectedCookiesGtk(GetNativeHandle(), tab_contents); | 889 new CollectedCookiesGtk(GetNativeHandle(), tab_contents); |
897 } | 890 } |
898 | 891 |
899 void BrowserWindowGtk::ShowProfileErrorDialog(int message_id) { | 892 void BrowserWindowGtk::ShowProfileErrorDialog(int message_id) { |
900 std::string title = l10n_util::GetStringUTF8(IDS_PRODUCT_NAME); | 893 std::string title = l10n_util::GetStringUTF8(IDS_PRODUCT_NAME); |
901 std::string message = l10n_util::GetStringUTF8(message_id); | 894 std::string message = l10n_util::GetStringUTF8(message_id); |
902 GtkWidget* dialog = gtk_message_dialog_new(window_, | 895 GtkWidget* dialog = gtk_message_dialog_new(window_, |
903 static_cast<GtkDialogFlags>(0), GTK_MESSAGE_WARNING, GTK_BUTTONS_OK, | 896 static_cast<GtkDialogFlags>(0), GTK_MESSAGE_WARNING, GTK_BUTTONS_OK, |
(...skipping 1346 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2250 // special-case the ones where the custom frame should be used. These names | 2243 // special-case the ones where the custom frame should be used. These names |
2251 // are taken from the WMs' source code. | 2244 // are taken from the WMs' source code. |
2252 return (wm_name == "Blackbox" || | 2245 return (wm_name == "Blackbox" || |
2253 wm_name == "compiz" || | 2246 wm_name == "compiz" || |
2254 wm_name == "e16" || // Enlightenment DR16 | 2247 wm_name == "e16" || // Enlightenment DR16 |
2255 wm_name == "Metacity" || | 2248 wm_name == "Metacity" || |
2256 wm_name == "Mutter" || | 2249 wm_name == "Mutter" || |
2257 wm_name == "Openbox" || | 2250 wm_name == "Openbox" || |
2258 wm_name == "Xfwm4"); | 2251 wm_name == "Xfwm4"); |
2259 } | 2252 } |
OLD | NEW |