]> Pileus Git - ~andy/gtk/commitdiff
only store the size if we can resize in that direction.
authorJonathan Blandford <jrb@redhat.com>
Mon, 1 Mar 2004 21:52:04 +0000 (21:52 +0000)
committerJonathan Blandford <jrb@src.gnome.org>
Mon, 1 Mar 2004 21:52:04 +0000 (21:52 +0000)
Mon Mar  1 16:51:21 2004  Jonathan Blandford  <jrb@redhat.com>

        * gtk/gtkfilechooserdialog.c
        (file_chooser_widget_default_size_changed): only store the size if
        we can resize in that direction.

ChangeLog
ChangeLog.pre-2-10
ChangeLog.pre-2-4
ChangeLog.pre-2-6
ChangeLog.pre-2-8
gtk/gtkfilechooserdefault.c
gtk/gtkfilechooserdialog.c

index 4a4baf9385322de3e8a2a03cdf18ae60cbadbd86..f69483c38f330aa5963e5b4617cd32d7114ee9a2 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,9 @@
+Mon Mar  1 16:51:21 2004  Jonathan Blandford  <jrb@redhat.com>
+
+       * gtk/gtkfilechooserdialog.c
+       (file_chooser_widget_default_size_changed): only store the size if
+       we can resize in that direction.
+
 Mon Mar  1 16:32:52 2004  Jonathan Blandford  <jrb@redhat.com>
 
        * gtk/gtkfilechooserwidget.c
index 4a4baf9385322de3e8a2a03cdf18ae60cbadbd86..f69483c38f330aa5963e5b4617cd32d7114ee9a2 100644 (file)
@@ -1,3 +1,9 @@
+Mon Mar  1 16:51:21 2004  Jonathan Blandford  <jrb@redhat.com>
+
+       * gtk/gtkfilechooserdialog.c
+       (file_chooser_widget_default_size_changed): only store the size if
+       we can resize in that direction.
+
 Mon Mar  1 16:32:52 2004  Jonathan Blandford  <jrb@redhat.com>
 
        * gtk/gtkfilechooserwidget.c
index 4a4baf9385322de3e8a2a03cdf18ae60cbadbd86..f69483c38f330aa5963e5b4617cd32d7114ee9a2 100644 (file)
@@ -1,3 +1,9 @@
+Mon Mar  1 16:51:21 2004  Jonathan Blandford  <jrb@redhat.com>
+
+       * gtk/gtkfilechooserdialog.c
+       (file_chooser_widget_default_size_changed): only store the size if
+       we can resize in that direction.
+
 Mon Mar  1 16:32:52 2004  Jonathan Blandford  <jrb@redhat.com>
 
        * gtk/gtkfilechooserwidget.c
index 4a4baf9385322de3e8a2a03cdf18ae60cbadbd86..f69483c38f330aa5963e5b4617cd32d7114ee9a2 100644 (file)
@@ -1,3 +1,9 @@
+Mon Mar  1 16:51:21 2004  Jonathan Blandford  <jrb@redhat.com>
+
+       * gtk/gtkfilechooserdialog.c
+       (file_chooser_widget_default_size_changed): only store the size if
+       we can resize in that direction.
+
 Mon Mar  1 16:32:52 2004  Jonathan Blandford  <jrb@redhat.com>
 
        * gtk/gtkfilechooserwidget.c
index 4a4baf9385322de3e8a2a03cdf18ae60cbadbd86..f69483c38f330aa5963e5b4617cd32d7114ee9a2 100644 (file)
@@ -1,3 +1,9 @@
+Mon Mar  1 16:51:21 2004  Jonathan Blandford  <jrb@redhat.com>
+
+       * gtk/gtkfilechooserdialog.c
+       (file_chooser_widget_default_size_changed): only store the size if
+       we can resize in that direction.
+
 Mon Mar  1 16:32:52 2004  Jonathan Blandford  <jrb@redhat.com>
 
        * gtk/gtkfilechooserwidget.c
index c56a01060ee49edf4c8f6e8a1bafa80f68c6bd72..41f7dc686563edc30461bc1d8a4e1a835a255739 100644 (file)
@@ -1886,7 +1886,7 @@ save_widgets_create (GtkFileChooserDefault *impl)
   gtk_widget_show (widget);
 
   impl->save_file_name_entry = gtk_entry_new ();
-  gtk_entry_set_width_chars (GTK_ENTRY (impl->save_file_name_entry), 25);
+  gtk_entry_set_width_chars (GTK_ENTRY (impl->save_file_name_entry), 45);
   gtk_entry_set_activates_default (GTK_ENTRY (impl->save_file_name_entry), TRUE);
   gtk_table_attach (GTK_TABLE (table), impl->save_file_name_entry,
                    1, 2, 0, 1,
@@ -3193,7 +3193,10 @@ gtk_file_chooser_default_get_resizable_hints (GtkFileChooserEmbed *chooser_embed
          impl->action == GTK_FILE_CHOOSER_ACTION_CREATE_FOLDER)
        {
          if (! gtk_expander_get_expanded (GTK_EXPANDER (impl->save_expander)))
-           *resize_vertically = FALSE;
+           {
+             *resize_vertically = FALSE;
+             *resize_horizontally = FALSE;
+           }
        }
     }
 }
index db4dff6676d4a877ed35d4395e2d182307a87b23..d40664eb4c396b54d9e46cdd350369fa00aa48b2 100644 (file)
@@ -184,6 +184,8 @@ file_chooser_widget_default_size_changed (GtkWidget            *widget,
   gint extra_height;
   gint width, height;
   GtkRequisition req;
+  gboolean resize_horizontally;
+  gboolean resize_vertically;
 
   priv = GTK_FILE_CHOOSER_DIALOG_GET_PRIVATE (dialog);
 
@@ -221,8 +223,15 @@ file_chooser_widget_default_size_changed (GtkWidget            *widget,
     {
       gtk_window_resize (GTK_WINDOW (dialog), width, height);
     }
-  priv->default_width = width;
-  priv->default_height = height;
+
+  _gtk_file_chooser_embed_get_resizable_hints (GTK_FILE_CHOOSER_EMBED (priv->widget),
+                                              &resize_horizontally,
+                                              &resize_vertically);
+  /* Only store the size if we can resize in that direction. */
+  if (resize_horizontally)
+    priv->default_width = width;
+  if (resize_vertically)
+    priv->default_height = height;
 }