aboutsummaryrefslogtreecommitdiff
path: root/src/FocusableList.cc
diff options
context:
space:
mode:
authorMark Tiefenbruck <mark@fluxbox.org>2008-08-20 12:26:12 (GMT)
committerMark Tiefenbruck <mark@fluxbox.org>2008-08-20 12:26:12 (GMT)
commit4bf00f68573f3ad172b879e78ad441e74a916e66 (patch)
treea79a73aec7b643f0252d1f678e0a8c1703070576 /src/FocusableList.cc
parent0fea3e3c8640888e4ae6e76775f309f290134aab (diff)
downloadfluxbox-4bf00f68573f3ad172b879e78ad441e74a916e66.zip
fluxbox-4bf00f68573f3ad172b879e78ad441e74a916e66.tar.bz2
fix match limits in apps file, plus some documentation
Diffstat (limited to 'src/FocusableList.cc')
-rw-r--r--src/FocusableList.cc8
1 files changed, 6 insertions, 2 deletions
diff --git a/src/FocusableList.cc b/src/FocusableList.cc
index d15e10a..98492b8 100644
--- a/src/FocusableList.cc
+++ b/src/FocusableList.cc
@@ -156,10 +156,12 @@ void FocusableList::checkUpdate(Focusable &win) {
156 if (contains(win)) { 156 if (contains(win)) {
157 if (!m_pat->match(win)) { 157 if (!m_pat->match(win)) {
158 m_list.remove(&win); 158 m_list.remove(&win);
159 m_pat->removeMatch();
159 m_removesig.notify(&win); 160 m_removesig.notify(&win);
160 } 161 }
161 } else if (m_pat->match(win)) { 162 } else if (m_pat->match(win)) {
162 insertFromParent(win); 163 insertFromParent(win);
164 m_pat->addMatch();
163 m_addsig.notify(&win); 165 m_addsig.notify(&win);
164 } 166 }
165} 167}
@@ -194,9 +196,10 @@ void FocusableList::addMatching() {
194 const Focusables list = m_parent->clientList(); 196 const Focusables list = m_parent->clientList();
195 Focusables::const_iterator it = list.begin(), it_end = list.end(); 197 Focusables::const_iterator it = list.begin(), it_end = list.end();
196 for (; it != it_end; ++it) { 198 for (; it != it_end; ++it) {
197 if (m_pat->match(**it)) 199 if (m_pat->match(**it)) {
198 pushBack(**it); 200 pushBack(**it);
199 else // we still want to watch it, in case it changes to match 201 m_pat->addMatch();
202 } else // we still want to watch it, in case it changes to match
200 attachSignals(**it); 203 attachSignals(**it);
201 } 204 }
202} 205}
@@ -279,6 +282,7 @@ void FocusableList::reset() {
279 detachSignals(*m_list.back()); 282 detachSignals(*m_list.back());
280 m_list.pop_back(); 283 m_list.pop_back();
281 } 284 }
285 m_pat->resetMatches();
282 if (m_parent) 286 if (m_parent)
283 addMatching(); 287 addMatching();
284 m_resetsig.notify(0); 288 m_resetsig.notify(0);