diff options
author | Marco Pesenti Gritti <marco@it.gnome.org> | 2003-03-17 02:45:16 +0800 |
---|---|---|
committer | Marco Pesenti Gritti <mpeseng@src.gnome.org> | 2003-03-17 02:45:16 +0800 |
commit | c24c8c4f38379dd0fa2bbc2d35e561c7023ec4aa (patch) | |
tree | f212f9107faa076933e8afc63ffe9f467cf0447b /src | |
parent | afb64e1503b7c459887710747be56522abf02e3e (diff) | |
download | gsoc2013-epiphany-c24c8c4f38379dd0fa2bbc2d35e561c7023ec4aa.tar gsoc2013-epiphany-c24c8c4f38379dd0fa2bbc2d35e561c7023ec4aa.tar.gz gsoc2013-epiphany-c24c8c4f38379dd0fa2bbc2d35e561c7023ec4aa.tar.bz2 gsoc2013-epiphany-c24c8c4f38379dd0fa2bbc2d35e561c7023ec4aa.tar.lz gsoc2013-epiphany-c24c8c4f38379dd0fa2bbc2d35e561c7023ec4aa.tar.xz gsoc2013-epiphany-c24c8c4f38379dd0fa2bbc2d35e561c7023ec4aa.tar.zst gsoc2013-epiphany-c24c8c4f38379dd0fa2bbc2d35e561c7023ec4aa.zip |
Cleanup filepicker api behavior. Put pdm buttons in a size group, to make
2003-03-16 Marco Pesenti Gritti <marco@it.gnome.org>
* embed/ephy-embed-utils.c: (ephy_embed_utils_save):
* embed/mozilla/mozilla-embed-single.cpp:
* src/pdm-dialog.c: (group_button_allocations), (pdm_dialog_init):
* src/window-commands.c: (window_cmd_file_open):
Cleanup filepicker api behavior.
Put pdm buttons in a size group, to make switching page smoother.
(from galeon)
Diffstat (limited to 'src')
-rwxr-xr-x | src/pdm-dialog.c | 27 | ||||
-rw-r--r-- | src/window-commands.c | 4 |
2 files changed, 29 insertions, 2 deletions
diff --git a/src/pdm-dialog.c b/src/pdm-dialog.c index fc0a102f0..a108cae88 100755 --- a/src/pdm-dialog.c +++ b/src/pdm-dialog.c @@ -471,6 +471,31 @@ pdm_dialog_passwords_free (PdmActionInfo *info, ephy_embed_single_free_passwords (single, l); } +/* Group all Properties and Remove buttons in the same size group to avoid the + * little jerk you get otherwise when switching pages because one set of + * buttons is wider than another. */ +static void +group_button_allocations (EphyDialog *dialog) +{ + const gint props[] = + { + PROP_COOKIES_REMOVE, + PROP_COOKIES_PROPERTIES, + PROP_PASSWORDS_REMOVE + }; + GtkSizeGroup *size_group; + guint i; + + size_group = gtk_size_group_new (GTK_SIZE_GROUP_HORIZONTAL); + + for (i = 0; i < G_N_ELEMENTS (props); ++i) + { + GtkWidget *w; + w = ephy_dialog_get_control (dialog, props[i]); + gtk_size_group_add_widget (size_group, w); + } +} + static void pdm_dialog_init (PdmDialog *dialog) { @@ -492,6 +517,8 @@ pdm_dialog_init (PdmDialog *dialog) "epiphany.glade", "pdm_dialog"); + group_button_allocations (EPHY_DIALOG (dialog)); + cookies_tv = setup_cookies_treeview (dialog); passwords_tv = setup_passwords_treeview (dialog); diff --git a/src/window-commands.c b/src/window-commands.c index c217b3bd4..bc793234d 100644 --- a/src/window-commands.c +++ b/src/window-commands.c @@ -287,7 +287,7 @@ window_cmd_file_open (EggAction *action, EphyWindow *window) { gchar *dir, *retDir; - gchar *file = NULL; + gchar *file; GnomeVFSURI *uri; GtkWidget *wmain; EphyEmbedShell *embed_shell; @@ -327,10 +327,10 @@ window_cmd_file_open (EggAction *action, g_free (retDir); gnome_vfs_uri_unref (uri); } + g_free (file); } g_free (dir); - g_free (file); } void |