diff options
author | evan@chromium.org <evan@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2010-01-20 22:38:08 +0000 |
---|---|---|
committer | evan@chromium.org <evan@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2010-01-20 22:38:08 +0000 |
commit | bca52adc0eb1e48ff4966a38fd25218d585c3709 (patch) | |
tree | 0fa3b386ca9a544b685340ae126f31e9d2a087ab /chrome/browser/gtk/first_run_dialog.cc | |
parent | b3f65d0dd1a60822606ac828f1b9bd2ec5dbc65c (diff) | |
download | chromium_src-bca52adc0eb1e48ff4966a38fd25218d585c3709.zip chromium_src-bca52adc0eb1e48ff4966a38fd25218d585c3709.tar.gz chromium_src-bca52adc0eb1e48ff4966a38fd25218d585c3709.tar.bz2 |
linux: let first run dialog size itself
Normally we'd rely on the sizes from our resources file, but
in this once case it makes a dialog much larger than necessary
due to different widgets in the Windows dialog.
TEST=first run dialog goes back to being small like it was last month
Review URL: http://codereview.chromium.org/548096
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@36692 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/gtk/first_run_dialog.cc')
-rw-r--r-- | chrome/browser/gtk/first_run_dialog.cc | 16 |
1 files changed, 10 insertions, 6 deletions
diff --git a/chrome/browser/gtk/first_run_dialog.cc b/chrome/browser/gtk/first_run_dialog.cc index 6bbb630..a38cb06 100644 --- a/chrome/browser/gtk/first_run_dialog.cc +++ b/chrome/browser/gtk/first_run_dialog.cc @@ -60,14 +60,18 @@ FirstRunDialog::FirstRunDialog(Profile* profile, int& response) l10n_util::GetStringUTF8(IDS_FIRSTRUN_DLG_OK).c_str(), GTK_STOCK_APPLY, GTK_RESPONSE_ACCEPT); + // Normally we would do the following: + // gtk_widget_realize(dialog_); + // gtk_util::SetWindowSizeFromResources(GTK_WINDOW(dialog_), + // IDS_FIRSTRUN_DIALOG_WIDTH_CHARS, + // -1, + // false); // resizable + // But because the first run dialog has extra widgets in Windows, the + // resources specify a dialog that is way too big. So instead in just this + // one case we let GTK size the dialog itself and just mark it non-resizable + // manually: gtk_window_set_resizable(GTK_WINDOW(dialog_), FALSE); - gtk_widget_realize(dialog_); - gtk_util::SetWindowSizeFromResources(GTK_WINDOW(dialog_), - IDS_FIRSTRUN_DIALOG_WIDTH_CHARS, - IDS_FIRSTRUN_DIALOG_HEIGHT_LINES, - true); - g_signal_connect(G_OBJECT(dialog_), "delete-event", G_CALLBACK(gtk_widget_hide_on_delete), NULL); |