[gnome-clocks] Really disconnect update_toolbar on stack destroy
- From: Stefano Facchini <sfacchini src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-clocks] Really disconnect update_toolbar on stack destroy
- Date: Fri, 8 Mar 2013 13:13:01 +0000 (UTC)
commit 7bfdfb7b809efb4fd1b770638874b640f3bfd5a1
Author: Stefano Facchini <stefano facchini gmail com>
Date: Fri Mar 8 14:15:52 2013 +0100
Really disconnect update_toolbar on stack destroy
src/window.vala | 10 ++++++----
1 files changed, 6 insertions(+), 4 deletions(-)
---
diff --git a/src/window.vala b/src/window.vala
index d25046e..8de8ced 100644
--- a/src/window.vala
+++ b/src/window.vala
@@ -73,17 +73,19 @@ public class Window : Gtk.ApplicationWindow {
stack.visible_child = (Gtk.Widget) c;
});
- stack.notify["visible-child"].connect (() => {
+ var stack_id = stack.notify["visible-child"].connect (() => {
update_toolbar ();
});
- var id = toolbar.notify["mode"].connect (() => {
+ var toolbar_id = toolbar.notify["mode"].connect (() => {
update_toolbar ();
});
stack.destroy.connect(() => {
- toolbar.disconnect (id);
- id = 0;
+ toolbar.disconnect (toolbar_id);
+ toolbar_id = 0;
+ stack.disconnect (stack_id);
+ stack_id = 0;
});
alarm.ring.connect ((w) => {
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]