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

Side by Side Diff: chrome/browser/gtk/import_progress_dialog_gtk.cc

Issue 131080: Linux: make import warning dialog modal. (Closed)
Patch Set: Created 11 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
« no previous file with comments | « chrome/browser/gtk/import_dialog_gtk.cc ('k') | chrome/browser/importer/importer.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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/gtk/import_progress_dialog_gtk.h" 5 #include "chrome/browser/gtk/import_progress_dialog_gtk.h"
6 6
7 #include "app/l10n_util.h" 7 #include "app/l10n_util.h"
8 #include "app/resource_bundle.h" 8 #include "app/resource_bundle.h"
9 #include "chrome/common/gtk_util.h" 9 #include "chrome/common/gtk_util.h"
10 #include "grit/chromium_strings.h" 10 #include "grit/chromium_strings.h"
(...skipping 104 matching lines...) Expand 10 before | Expand all | Expand 10 after
115 importer_host_->SetObserver(this); 115 importer_host_->SetObserver(this);
116 116
117 // Build the dialog. 117 // Build the dialog.
118 dialog_ = gtk_dialog_new_with_buttons( 118 dialog_ = gtk_dialog_new_with_buttons(
119 l10n_util::GetStringUTF8(IDS_IMPORT_PROGRESS_TITLE).c_str(), 119 l10n_util::GetStringUTF8(IDS_IMPORT_PROGRESS_TITLE).c_str(),
120 parent_, 120 parent_,
121 (GtkDialogFlags) (GTK_DIALOG_MODAL | GTK_DIALOG_NO_SEPARATOR), 121 (GtkDialogFlags) (GTK_DIALOG_MODAL | GTK_DIALOG_NO_SEPARATOR),
122 GTK_STOCK_CANCEL, 122 GTK_STOCK_CANCEL,
123 GTK_RESPONSE_REJECT, 123 GTK_RESPONSE_REJECT,
124 NULL); 124 NULL);
125 importer_host_->set_parent_window(GTK_WINDOW(dialog_));
125 126
126 GtkWidget* content_area = GTK_DIALOG(dialog_)->vbox; 127 GtkWidget* content_area = GTK_DIALOG(dialog_)->vbox;
127 gtk_box_set_spacing(GTK_BOX(content_area), gtk_util::kContentAreaSpacing); 128 gtk_box_set_spacing(GTK_BOX(content_area), gtk_util::kContentAreaSpacing);
128 129
129 GtkWidget* import_info = gtk_label_new( 130 GtkWidget* import_info = gtk_label_new(
130 l10n_util::GetStringFUTF8(IDS_IMPORT_PROGRESS_INFO, 131 l10n_util::GetStringFUTF8(IDS_IMPORT_PROGRESS_INFO,
131 source_profile).c_str()); 132 source_profile).c_str());
132 gtk_label_set_single_line_mode(GTK_LABEL(import_info), FALSE); 133 gtk_label_set_single_line_mode(GTK_LABEL(import_info), FALSE);
133 gtk_box_pack_start(GTK_BOX(content_area), import_info, FALSE, FALSE, 0); 134 gtk_box_pack_start(GTK_BOX(content_area), import_info, FALSE, FALSE, 0);
134 135
(...skipping 59 matching lines...) Expand 10 before | Expand all | Expand 10 after
194 ImporterHost* importer_host, 195 ImporterHost* importer_host,
195 const ProfileInfo& browser_profile, 196 const ProfileInfo& browser_profile,
196 Profile* profile, 197 Profile* profile,
197 ImportObserver* observer, 198 ImportObserver* observer,
198 bool first_run) { 199 bool first_run) {
199 DCHECK(items != 0); 200 DCHECK(items != 0);
200 ImportProgressDialogGtk::StartImport(parent, items, importer_host, 201 ImportProgressDialogGtk::StartImport(parent, items, importer_host,
201 browser_profile, profile, observer, 202 browser_profile, profile, observer,
202 first_run); 203 first_run);
203 } 204 }
OLDNEW
« no previous file with comments | « chrome/browser/gtk/import_dialog_gtk.cc ('k') | chrome/browser/importer/importer.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698