X-Git-Url: https://www.fi.muni.cz/~kas/git//home/kas/public_html/git/?a=blobdiff_plain;f=cut-n-paste%2Fevmountoperation%2Fev-mount-operation.c;h=0ce69847b1b5fec9231abcb0a6e576e4bc7f689e;hb=f675370b1c2f1e29dfb3a3b97eda5d46f6a4a4ae;hp=165c625a9738d7127c24f3eb347b6acaf7760350;hpb=526941f5d40276f39717de95010f0dd87e2e9c16;p=evince.git diff --git a/cut-n-paste/evmountoperation/ev-mount-operation.c b/cut-n-paste/evmountoperation/ev-mount-operation.c index 165c625a..0ce69847 100644 --- a/cut-n-paste/evmountoperation/ev-mount-operation.c +++ b/cut-n-paste/evmountoperation/ev-mount-operation.c @@ -578,13 +578,23 @@ ev_mount_operation_ask_password (GMountOperation *mount_op, G_CALLBACK (pw_dialog_got_response), operation); if (can_anonymous) - gtk_widget_set_sensitive (priv->entry_container, FALSE); + { + /* The anonymous option will be active by default, + * ensure the toggled signal is emitted for it. + */ + gtk_toggle_button_toggled (GTK_TOGGLE_BUTTON (priv->anonymous_toggle)); + } else if (! pw_dialog_input_is_valid (operation)) gtk_dialog_set_response_sensitive (dialog, GTK_RESPONSE_OK, FALSE); g_object_notify (G_OBJECT (operation), "is-showing"); - if (priv->parent_window == NULL && priv->screen) + if (priv->parent_window) + { + gtk_window_set_transient_for (window, priv->parent_window); + gtk_window_set_modal (window, TRUE); + } + else if (priv->screen) gtk_window_set_screen (GTK_WINDOW (dialog), priv->screen); gtk_widget_show_all (GTK_WIDGET (dialog));