diff options
author | Ettore Perazzoli <ettore@src.gnome.org> | 2001-12-20 14:05:51 +0800 |
---|---|---|
committer | Ettore Perazzoli <ettore@src.gnome.org> | 2001-12-20 14:05:51 +0800 |
commit | a33720dba790586bddfeb9fa7d7a04adf79878d2 (patch) | |
tree | d2f16139ad164e86365298d9e6993db8b50d79be | |
parent | 6cfbc6f4d946ea0976373b099284d5b5d5cfb4da (diff) | |
download | gsoc2013-evolution-a33720dba790586bddfeb9fa7d7a04adf79878d2.tar gsoc2013-evolution-a33720dba790586bddfeb9fa7d7a04adf79878d2.tar.gz gsoc2013-evolution-a33720dba790586bddfeb9fa7d7a04adf79878d2.tar.bz2 gsoc2013-evolution-a33720dba790586bddfeb9fa7d7a04adf79878d2.tar.lz gsoc2013-evolution-a33720dba790586bddfeb9fa7d7a04adf79878d2.tar.xz gsoc2013-evolution-a33720dba790586bddfeb9fa7d7a04adf79878d2.tar.zst gsoc2013-evolution-a33720dba790586bddfeb9fa7d7a04adf79878d2.zip |
-- Merging patches from evolution-1-0-branch.
* e-shell-about-box.c: Add Michael MacDonald.
[Fixes #17377, Evolution doesn't work on multi-depth displays.]
* main.c (main): Push GdkRGB visual and colormap.
[Fix #16693. What happens there is that the user closed the
dialog before the async operation was completed, so when the
notification was received the shell crashed.]
* e-shell-folder-creation-dialog.c: New member
`creation_in_progress' in `DialogData'.
(e_shell_show_folder_creation_dialog): Init to %FALSE.
(async_create_cb): Set to %FALSE. Also, if the
dialog_data->dialog is %NULL, free the dialog_data before
returning.
(dialog_clicked_cb): Set to %TRUE.
(dialog_destroy_cb): If a creation is in progress, just set the
widget pointers in the DialogData struct to %NULL instead of
freeing the whole struct.
(async_create_cb): Make the OK and Cancel buttons sensitive.
(dialog_clicked_cb): Make them insensitive here.
svn path=/trunk/; revision=15192
-rw-r--r-- | shell/ChangeLog | 42 | ||||
-rw-r--r-- | shell/e-shell-about-box.c | 1 | ||||
-rw-r--r-- | shell/e-shell-folder-creation-dialog.c | 40 | ||||
-rw-r--r-- | shell/main.c | 3 |
4 files changed, 81 insertions, 5 deletions
diff --git a/shell/ChangeLog b/shell/ChangeLog index 482f7e111f..3b9ecb2998 100644 --- a/shell/ChangeLog +++ b/shell/ChangeLog @@ -1,4 +1,33 @@ -2001-12-14 Ettore Perazzoli <ettore@ximian.com> +2001-12-17 Ettore Perazzoli <ettore@ximian.com> + + * e-shell-about-box.c: Add Michael MacDonald. + +2001-12-17 Ettore Perazzoli <ettore@ximian.com> + + [Fix #17377, Evolution doesn't work on multi-depth displays.] + + * main.c (main): Push GdkRGB visual and colormap. + +2001-12-17 Ettore Perazzoli <ettore@ximian.com> + + [Fix #16693. What happens there is that the user closed the + dialog before the async operation was completed, so when the + notification was received the shell crashed.] + + * e-shell-folder-creation-dialog.c: New member + `creation_in_progress' in `DialogData'. + (e_shell_show_folder_creation_dialog): Init to %FALSE. + (async_create_cb): Set to %FALSE. Also, if the + dialog_data->dialog is %NULL, free the dialog_data before + returning. + (dialog_clicked_cb): Set to %TRUE. + (dialog_destroy_cb): If a creation is in progress, just set the + widget pointers in the DialogData struct to %NULL instead of + freeing the whole struct. + (async_create_cb): Make the OK and Cancel buttons sensitive. + (dialog_clicked_cb): Make them insensitive here. + +2001-12-12 Ettore Perazzoli <ettore@ximian.com> [Fix #17258, shell displays splash even if Evolution is already running.] @@ -6,7 +35,7 @@ * e-shell.c (e_shell_construct): Display the splash screen only if the registration succeeds. -2001-12-12 Ettore Perazzoli <ettore@ximian.com> +2001-12-10 Ettore Perazzoli <ettore@ximian.com> [Fix #14838, saving passwords doesn't work. It is actually a workaround for some obscure Bonobo-conf bug.] @@ -15,10 +44,15 @@ function to create the `~/evolution/private' directory. (e_setup): Call it. -2001-12-05 Ettore Perazzoli <ettore@ximian.com> +2001-12-07 Iain Holmes <iain@ximian.com> - * e-shell-about-box.c: Add missing comma. + [Trying to fix #14701, importing locks up Evolution.] + * e-shell-importer.c (show_error): Show an error message, but not + modally. + (start_import): Use above function so none of the errors are modal. + (folder_selected): Hide the folder dialog. + 2001-12-04 Ettore Perazzoli <ettore@ximian.com> [Fix #7827, Switching desktops leaves the folder bar popped up.] diff --git a/shell/e-shell-about-box.c b/shell/e-shell-about-box.c index 26e324bb8b..491434669b 100644 --- a/shell/e-shell-about-box.c +++ b/shell/e-shell-about-box.c @@ -64,6 +64,7 @@ static const char *text[] = { "Miles Lane", "Jason Leach", "Matthew Loper", + "Michael MacDonald", "Kjartan Maraas", "Michael Meeks", "Federico Mena", diff --git a/shell/e-shell-folder-creation-dialog.c b/shell/e-shell-folder-creation-dialog.c index 9def913951..dbbdcdfd74 100644 --- a/shell/e-shell-folder-creation-dialog.c +++ b/shell/e-shell-folder-creation-dialog.c @@ -61,6 +61,8 @@ struct _DialogData { EShellFolderCreationDialogCallback result_callback; void *result_callback_data; + + gboolean creation_in_progress; }; typedef struct _DialogData DialogData; @@ -85,6 +87,11 @@ async_create_cb (EStorageSet *storage_set, dialog_data = (DialogData *) data; + dialog_data->creation_in_progress = FALSE; + + gnome_dialog_set_sensitive (GNOME_DIALOG (dialog_data->dialog), 0, TRUE); + gnome_dialog_set_sensitive (GNOME_DIALOG (dialog_data->dialog), 1, TRUE); + if (result == E_STORAGE_OK) { /* Success! Tell the callback of this, then return */ if (dialog_data->result_callback != NULL) @@ -92,7 +99,14 @@ async_create_cb (EStorageSet *storage_set, E_SHELL_FOLDER_CREATION_DIALOG_RESULT_SUCCESS, dialog_data->folder_path, dialog_data->result_callback_data); - gtk_widget_destroy (dialog_data->dialog); + if (dialog_data->dialog != NULL) { + gtk_widget_destroy (dialog_data->dialog); + } else { + /* If dialog_data->dialog is NULL, it means that the + dialog has been destroyed before we were done, so we + have to free the dialog_data ourselves. */ + dialog_data_destroy (dialog_data); + } return; } else if (result == E_STORAGE_EXISTS) { e_storage_set_view_set_current_folder (E_STORAGE_SET_VIEW (dialog_data->storage_set_view), @@ -110,6 +124,12 @@ async_create_cb (EStorageSet *storage_set, e_notice (GTK_WINDOW (dialog_data->dialog), GNOME_MESSAGE_BOX_ERROR, _("Cannot create the specified folder:\n%s"), e_storage_result_to_string (result)); + + /* If dialog_data->dialog is NULL, it means that the dialog has been + destroyed before we were done, so we have to free the dialog_data + ourselves. */ + if (dialog_data->dialog == NULL) + dialog_data_destroy (dialog_data); } @@ -177,6 +197,11 @@ dialog_clicked_cb (GnomeDialog *dialog, g_free (dialog_data->folder_path); dialog_data->folder_path = path; + gnome_dialog_set_sensitive (dialog, 0, FALSE); + gnome_dialog_set_sensitive (dialog, 1, FALSE); + + dialog_data->creation_in_progress = TRUE; + e_storage_set_async_create_folder (storage_set, path, folder_type, @@ -191,6 +216,18 @@ dialog_destroy_cb (GtkObject *object, DialogData *dialog_data; dialog_data = (DialogData *) data; + + if (dialog_data->creation_in_progress) { + /* If the dialog has been closed before we are done creating + the folder, the dialog_data will be freed after the creation + is completed. */ + dialog_data->dialog = NULL; + dialog_data->folder_name_entry = NULL; + dialog_data->storage_set_view = NULL; + dialog_data->folder_type_option_menu = NULL; + return; + } + dialog_data_destroy (dialog_data); } @@ -500,6 +537,7 @@ e_shell_show_folder_creation_dialog (EShell *shell, dialog_data->folder_path = NULL; dialog_data->result_callback = result_callback; dialog_data->result_callback_data = result_callback_data; + dialog_data->creation_in_progress = FALSE; gtk_signal_connect (GTK_OBJECT (dialog), "clicked", GTK_SIGNAL_FUNC (dialog_clicked_cb), dialog_data); diff --git a/shell/main.c b/shell/main.c index 06aefd84cc..766d6e6d7d 100644 --- a/shell/main.c +++ b/shell/main.c @@ -351,6 +351,9 @@ main (int argc, char **argv) gtk_idle_add (idle_cb, uri_list); + gtk_widget_push_visual (gdk_rgb_get_visual ()); + gtk_widget_push_colormap (gdk_rgb_get_cmap ()); + bonobo_main (); return 0; |