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

Unified Diff: chrome/browser/ui/gtk/gtk_util.cc

Issue 7791004: linux: delete code that worked around gtk <2.18 (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 9 years, 4 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « chrome/browser/ui/gtk/global_bookmark_menu.cc ('k') | chrome/browser/ui/gtk/menu_gtk.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/ui/gtk/gtk_util.cc
diff --git a/chrome/browser/ui/gtk/gtk_util.cc b/chrome/browser/ui/gtk/gtk_util.cc
index 2a8160d957b2aa6503a83edaf584a3e6deb0fee8..bcf2d7e0628212a08a7f5f3bf11638229cf9347c 100644
--- a/chrome/browser/ui/gtk/gtk_util.cc
+++ b/chrome/browser/ui/gtk/gtk_util.cc
@@ -384,7 +384,6 @@ void CenterOverWindow(GtkWindow* window, GtkWindow* parent) {
}
void MakeAppModalWindowGroup() {
-#if GTK_CHECK_VERSION(2, 14, 0)
// Older versions of GTK+ don't give us gtk_window_group_list() which is what
// we need to add current non-browser modal dialogs to the list. If
// we have 2.14+ we can do things the correct way.
@@ -402,20 +401,9 @@ void MakeAppModalWindowGroup() {
g_list_free(all_windows);
}
g_object_unref(window_group);
-#else
- // Otherwise just grab all browser windows and be slightly broken.
- GtkWindowGroup* window_group = gtk_window_group_new();
- for (BrowserList::const_iterator it = BrowserList::begin();
- it != BrowserList::end(); ++it) {
- gtk_window_group_add_window(window_group,
- (*it)->window()->GetNativeHandle());
- }
- g_object_unref(window_group);
-#endif
}
void AppModalDismissedUngroupWindows() {
-#if GTK_CHECK_VERSION(2, 14, 0)
if (BrowserList::begin() != BrowserList::end()) {
std::vector<GtkWindow*> transient_windows;
@@ -444,17 +432,6 @@ void AppModalDismissedUngroupWindows() {
gtk_window_group_add_window(group, *it);
}
}
-#else
- // This is slightly broken in the case where a different window had a dialog,
- // but its the best we can do since we don't have newer gtk stuff.
- for (BrowserList::const_iterator it = BrowserList::begin();
- it != BrowserList::end(); ++it) {
- GtkWindowGroup* window_group = gtk_window_group_new();
- gtk_window_group_add_window(window_group,
- (*it)->window()->GetNativeHandle());
- g_object_unref(window_group);
- }
-#endif
}
void RemoveAllChildren(GtkWidget* container) {
« no previous file with comments | « chrome/browser/ui/gtk/global_bookmark_menu.cc ('k') | chrome/browser/ui/gtk/menu_gtk.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698