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

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

Issue 7569012: gtk: Use gtk_dialog_get_content_area() throughout. (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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
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/first_run_dialog.h" 5 #include "chrome/browser/ui/gtk/first_run_dialog.h"
6 6
7 #include <string> 7 #include <string>
8 #include <vector> 8 #include <vector>
9 9
10 #include "base/i18n/rtl.h" 10 #include "base/i18n/rtl.h"
(...skipping 250 matching lines...) Expand 10 before | Expand all | Expand 10 after
261 gtk_util::AddButtonToDialog(dialog_, 261 gtk_util::AddButtonToDialog(dialog_,
262 l10n_util::GetStringUTF8(IDS_FIRSTRUN_DLG_OK).c_str(), 262 l10n_util::GetStringUTF8(IDS_FIRSTRUN_DLG_OK).c_str(),
263 GTK_STOCK_APPLY, GTK_RESPONSE_ACCEPT); 263 GTK_STOCK_APPLY, GTK_RESPONSE_ACCEPT);
264 gtk_window_set_deletable(GTK_WINDOW(dialog_), FALSE); 264 gtk_window_set_deletable(GTK_WINDOW(dialog_), FALSE);
265 265
266 gtk_window_set_resizable(GTK_WINDOW(dialog_), FALSE); 266 gtk_window_set_resizable(GTK_WINDOW(dialog_), FALSE);
267 267
268 g_signal_connect(dialog_, "delete-event", 268 g_signal_connect(dialog_, "delete-event",
269 G_CALLBACK(gtk_widget_hide_on_delete), NULL); 269 G_CALLBACK(gtk_widget_hide_on_delete), NULL);
270 270
271 GtkWidget* content_area = GTK_DIALOG(dialog_)->vbox; 271 GtkWidget* content_area = gtk_dialog_get_content_area(GTK_DIALOG(dialog_));
272 272
273 make_default_ = gtk_check_button_new_with_label( 273 make_default_ = gtk_check_button_new_with_label(
274 l10n_util::GetStringUTF8(IDS_FR_CUSTOMIZE_DEFAULT_BROWSER).c_str()); 274 l10n_util::GetStringUTF8(IDS_FR_CUSTOMIZE_DEFAULT_BROWSER).c_str());
275 gtk_toggle_button_set_active(GTK_TOGGLE_BUTTON(make_default_), TRUE); 275 gtk_toggle_button_set_active(GTK_TOGGLE_BUTTON(make_default_), TRUE);
276 gtk_box_pack_start(GTK_BOX(content_area), make_default_, FALSE, FALSE, 0); 276 gtk_box_pack_start(GTK_BOX(content_area), make_default_, FALSE, FALSE, 0);
277 277
278 report_crashes_ = gtk_check_button_new(); 278 report_crashes_ = gtk_check_button_new();
279 GtkWidget* check_label = gtk_label_new( 279 GtkWidget* check_label = gtk_label_new(
280 l10n_util::GetStringUTF8(IDS_OPTIONS_ENABLE_LOGGING).c_str()); 280 l10n_util::GetStringUTF8(IDS_OPTIONS_ENABLE_LOGGING).c_str());
281 gtk_label_set_line_wrap(GTK_LABEL(check_label), TRUE); 281 gtk_label_set_line_wrap(GTK_LABEL(check_label), TRUE);
(...skipping 149 matching lines...) Expand 10 before | Expand all | Expand 10 after
431 } 431 }
432 432
433 void FirstRunDialog::FirstRunDone() { 433 void FirstRunDialog::FirstRunDone() {
434 FirstRun::SetShowWelcomePagePref(); 434 FirstRun::SetShowWelcomePagePref();
435 435
436 if (dialog_) 436 if (dialog_)
437 gtk_widget_destroy(dialog_); 437 gtk_widget_destroy(dialog_);
438 MessageLoop::current()->Quit(); 438 MessageLoop::current()->Quit();
439 delete this; 439 delete this;
440 } 440 }
OLDNEW
« no previous file with comments | « chrome/browser/ui/gtk/extensions/extension_uninstall_dialog_gtk.cc ('k') | chrome/browser/ui/gtk/hung_renderer_dialog_gtk.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698