bgo322298 - Make the file chooser dialog always resizable
2008-05-19 Federico Mena Quintero <federico@novell.com> http://bugzilla.gnome.org/show_bug.cgi?id=322298 - Save dialog can't be resized until you expand the "Browse for other folders" section. * gtk/gtkfilechooserembed.h (struct _GtkFileChooserEmbedIface): Removed the "get_resizable" method. (_gtk_file_chooser_embed_get_resizable): Removed. * gtk/gtkfilechooserembed.c: Removed the _get_resizable() machinery. * gtk/gtkfilechooserdefault.c: Likewise. * gtk/gtkfilechooserdialog.c (file_chooser_widget_default_size_changed): Act as if the dialog were always resizable. Signed-off-by: Federico Mena Quintero <federico@novell.com> svn path=/trunk/; revision=20113
This commit is contained in:
committed by
Federico Mena Quintero
parent
02fd7ba040
commit
20ee3a022e
@ -185,7 +185,6 @@ file_chooser_widget_default_size_changed (GtkWidget *widget,
|
||||
gint width, height;
|
||||
gint default_width, default_height;
|
||||
GtkRequisition req, widget_req;
|
||||
gboolean resizable;
|
||||
|
||||
priv = GTK_FILE_CHOOSER_DIALOG_GET_PRIVATE (dialog);
|
||||
|
||||
@ -208,7 +207,6 @@ file_chooser_widget_default_size_changed (GtkWidget *widget,
|
||||
height = GTK_WIDGET (dialog)->allocation.height - widget->allocation.height;
|
||||
}
|
||||
|
||||
resizable = _gtk_file_chooser_embed_get_resizable (GTK_FILE_CHOOSER_EMBED (priv->widget));
|
||||
_gtk_file_chooser_embed_get_default_size (GTK_FILE_CHOOSER_EMBED (priv->widget),
|
||||
&default_width, &default_height);
|
||||
|
||||
@ -219,16 +217,7 @@ file_chooser_widget_default_size_changed (GtkWidget *widget,
|
||||
if (GTK_WIDGET_REALIZED (dialog))
|
||||
clamp_to_screen (GTK_WIDGET (dialog), &width, &height);
|
||||
|
||||
if (resizable)
|
||||
{
|
||||
gtk_window_set_resizable (GTK_WINDOW (dialog), resizable);
|
||||
gtk_window_resize (GTK_WINDOW (dialog), width, height);
|
||||
}
|
||||
else
|
||||
{
|
||||
gtk_widget_set_size_request (GTK_WIDGET (dialog), width, -1);
|
||||
gtk_window_set_resizable (GTK_WINDOW (dialog), resizable);
|
||||
}
|
||||
gtk_window_resize (GTK_WINDOW (dialog), width, height);
|
||||
}
|
||||
|
||||
static void
|
||||
|
||||
Reference in New Issue
Block a user