diff options
author | Mathias Gumz <akira at fluxbox dot org> | 2011-02-23 20:45:50 (GMT) |
---|---|---|
committer | Mathias Gumz <akira at fluxbox dot org> | 2011-02-23 20:45:50 (GMT) |
commit | 32cc4ba69b78b496524b11cd9f76328820ccaef1 (patch) | |
tree | e3d78692478c4f84fdfd712049e6830d427bb084 /src/FbTk/MultLayers.cc | |
parent | 504fd5c4fac2ef8d7df7ea61baccc00977ea4f7b (diff) | |
download | fluxbox-32cc4ba69b78b496524b11cd9f76328820ccaef1.zip fluxbox-32cc4ba69b78b496524b11cd9f76328820ccaef1.tar.bz2 |
code deduplication
Diffstat (limited to 'src/FbTk/MultLayers.cc')
-rw-r--r-- | src/FbTk/MultLayers.cc | 23 |
1 files changed, 1 insertions, 22 deletions
diff --git a/src/FbTk/MultLayers.cc b/src/FbTk/MultLayers.cc index 6469a14..0f0748f 100644 --- a/src/FbTk/MultLayers.cc +++ b/src/FbTk/MultLayers.cc | |||
@@ -114,28 +114,7 @@ void MultLayers::restack() { | |||
114 | if (!isUpdatable()) | 114 | if (!isUpdatable()) |
115 | return; | 115 | return; |
116 | 116 | ||
117 | int layernum=0, winnum=0, size = this->size(); | 117 | XLayer::restack(m_layers); |
118 | |||
119 | Window *winlist = new Window[size]; | ||
120 | for (layernum=0; layernum < static_cast<signed>(m_layers.size()); layernum++) { | ||
121 | |||
122 | XLayer::ItemList::iterator it = m_layers[layernum]->getItemList().begin(); | ||
123 | XLayer::ItemList::iterator it_end = m_layers[layernum]->getItemList().end(); | ||
124 | |||
125 | // add all windows from each layeritem in each layer | ||
126 | for (; it != it_end; ++it) { | ||
127 | XLayerItem::Windows::const_iterator wit = (*it)->getWindows().begin(); | ||
128 | XLayerItem::Windows::const_iterator wit_end = (*it)->getWindows().end(); | ||
129 | for (; wit != wit_end; ++wit) { | ||
130 | if ((*wit)->window()) | ||
131 | winlist[winnum++] = (*wit)->window(); | ||
132 | } | ||
133 | } | ||
134 | } | ||
135 | |||
136 | XRestackWindows(FbTk::App::instance()->display(), winlist, winnum); | ||
137 | |||
138 | delete [] winlist; | ||
139 | } | 118 | } |
140 | 119 | ||
141 | int MultLayers::size() { | 120 | int MultLayers::size() { |