diff options
author | Pavel Labath <pavelo@centrum.sk> | 2011-08-08 11:31:25 (GMT) |
---|---|---|
committer | Pavel Labath <pavelo@centrum.sk> | 2011-09-14 17:39:11 (GMT) |
commit | e54bca68d2bd42f9b9c342a1564971db6e071808 (patch) | |
tree | 61f149ac9e1d7575f5da5aeaf1501c044a9e5f68 /src/FocusableList.hh | |
parent | aa84c952535a86e797226a2fe3bc5f41248c93c1 (diff) | |
download | fluxbox-e54bca68d2bd42f9b9c342a1564971db6e071808.zip fluxbox-e54bca68d2bd42f9b9c342a1564971db6e071808.tar.bz2 |
Make sure FocusableList disconnects from signals when it is destroyed
Diffstat (limited to 'src/FocusableList.hh')
-rw-r--r-- | src/FocusableList.hh | 13 |
1 files changed, 6 insertions, 7 deletions
diff --git a/src/FocusableList.hh b/src/FocusableList.hh index 48881d0..a56fdbd 100644 --- a/src/FocusableList.hh +++ b/src/FocusableList.hh | |||
@@ -78,10 +78,10 @@ public: | |||
78 | @name signals | 78 | @name signals |
79 | @{ | 79 | @{ |
80 | */ | 80 | */ |
81 | FbTk::Signal<Focusable *> &orderSig() { return m_ordersig; } | 81 | const FbTk::Signal<Focusable *> &orderSig() const { return m_ordersig; } |
82 | FbTk::Signal<Focusable *> &addSig() { return m_addsig; } | 82 | const FbTk::Signal<Focusable *> &addSig() const { return m_addsig; } |
83 | FbTk::Signal<Focusable *> &removeSig() { return m_removesig; } | 83 | const FbTk::Signal<Focusable *> &removeSig() const { return m_removesig; } |
84 | FbTk::Signal<> &resetSig() { return m_resetsig; } | 84 | const FbTk::Signal<> &resetSig() const { return m_resetsig; } |
85 | /** @} */ // end group signals | 85 | /** @} */ // end group signals |
86 | 86 | ||
87 | private: | 87 | private: |
@@ -91,7 +91,6 @@ private: | |||
91 | bool insertFromParent(Focusable &win); | 91 | bool insertFromParent(Focusable &win); |
92 | void attachSignals(Focusable &win); | 92 | void attachSignals(Focusable &win); |
93 | void reset(); | 93 | void reset(); |
94 | void attachChild(FocusableList &child) const; | ||
95 | void workspaceChanged(BScreen &screen); | 94 | void workspaceChanged(BScreen &screen); |
96 | void focusedWindowChanged(BScreen &screen, FluxboxWindow *win, WinClient *client); | 95 | void focusedWindowChanged(BScreen &screen, FluxboxWindow *win, WinClient *client); |
97 | /// Title has changed for a window | 96 | /// Title has changed for a window |
@@ -108,8 +107,8 @@ private: | |||
108 | BScreen &m_screen; | 107 | BScreen &m_screen; |
109 | std::list<Focusable *> m_list; | 108 | std::list<Focusable *> m_list; |
110 | 109 | ||
111 | mutable FbTk::Signal<Focusable *> m_ordersig, m_addsig, m_removesig; | 110 | FbTk::Signal<Focusable *> m_ordersig, m_addsig, m_removesig; |
112 | mutable FbTk::Signal<> m_resetsig; | 111 | FbTk::Signal<> m_resetsig; |
113 | typedef std::map<Focusable*, FbTk::RefCount<FbTk::SignalTracker> > SignalMap; | 112 | typedef std::map<Focusable*, FbTk::RefCount<FbTk::SignalTracker> > SignalMap; |
114 | SignalMap m_signal_map; | 113 | SignalMap m_signal_map; |
115 | }; | 114 | }; |