[tomboy] When disabling a note, disable entire window, and save focus widget
- From: Sanford Armstrong <sharm src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [tomboy] When disabling a note, disable entire window, and save focus widget
- Date: Mon, 8 Mar 2010 19:25:55 +0000 (UTC)
commit 04ba810e6d7c5535445cb1763d2b8444bb50f075
Author: Sandy Armstrong <sanfordarmstrong gmail com>
Date: Mon Mar 8 07:44:12 2010 -0800
When disabling a note, disable entire window, and save focus widget
Now the toolbar and other widgets are disabled, and you don't lose your
cursor after a sync.
Tomboy/Note.cs | 10 ++++++++--
1 files changed, 8 insertions(+), 2 deletions(-)
---
diff --git a/Tomboy/Note.cs b/Tomboy/Note.cs
index 665a7a5..21d6ec9 100644
--- a/Tomboy/Note.cs
+++ b/Tomboy/Note.cs
@@ -1086,13 +1086,19 @@ namespace Tomboy
}
}
+ private Gtk.Widget focusWidget;
public bool Enabled
{
get { return enabled; }
set {
enabled = value;
- if (window != null)
- window.Editor.Sensitive = enabled;
+ if (window != null) {
+ if (!enabled)
+ focusWidget = window.Focus;
+ window.Sensitive = enabled;
+ if (enabled)
+ window.Focus = focusWidget;
+ }
}
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]