[geary/wip/747627-drafts-not-saved-0.11: 4/4] Disable "save draft" button if it is not available yet. Bug 747627
- From: Michael Gratton <mjog src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [geary/wip/747627-drafts-not-saved-0.11: 4/4] Disable "save draft" button if it is not available yet. Bug 747627
- Date: Thu, 15 Dec 2016 00:19:59 +0000 (UTC)
commit 30e9b6f899202fc1c8f07bb46bc04c9ddf237041
Author: Gautier Pelloux-Prayer <gautier+git damsy net>
Date: Mon Nov 21 14:43:00 2016 +0100
Disable "save draft" button if it is not available yet. Bug 747627
src/client/composer/composer-widget.vala | 7 +++++--
1 files changed, 5 insertions(+), 2 deletions(-)
---
diff --git a/src/client/composer/composer-widget.vala b/src/client/composer/composer-widget.vala
index deec781..545ba74 100644
--- a/src/client/composer/composer-widget.vala
+++ b/src/client/composer/composer-widget.vala
@@ -1150,7 +1150,7 @@ public class ComposerWidget : Gtk.EventBox {
if (can_save())
save_and_exit_async.begin();
else
- container.close_container();
+ on_close(action, param);
}
private void on_close_and_discard() {
@@ -1381,9 +1381,12 @@ public class ComposerWidget : Gtk.EventBox {
Cancellable? cancellable = null)
throws Error {
this.draft_save_text = "";
+ SimpleAction close_and_save = get_action(ACTION_CLOSE_AND_SAVE);
+
+ close_and_save.set_enabled(false);
+
yield close_draft_manager_async(cancellable);
- Gtk.Action close_and_save = this.actions.get_action(ACTION_CLOSE_SAVE);
if (!this.account.information.save_drafts) {
close_and_save.set_visible(false);
return;
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]