summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/Basemenu.cc11
-rw-r--r--src/Workspace.cc12
2 files changed, 9 insertions, 14 deletions
diff --git a/src/Basemenu.cc b/src/Basemenu.cc
index 87c4bf6..2f7de99 100644
--- a/src/Basemenu.cc
+++ b/src/Basemenu.cc
@@ -22,7 +22,7 @@
22// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER 22// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
23// DEALINGS IN THE SOFTWARE. 23// DEALINGS IN THE SOFTWARE.
24 24
25// $Id: Basemenu.cc,v 1.28 2002/08/04 15:19:34 fluxgen Exp $ 25// $Id: Basemenu.cc,v 1.29 2002/09/09 10:01:41 fluxgen Exp $
26 26
27//use GNU extensions 27//use GNU extensions
28#ifndef _GNU_SOURCE 28#ifndef _GNU_SOURCE
@@ -221,12 +221,11 @@ int Basemenu::insert(const char *label, Basemenu *submenu, int pos) {
221 221
222int Basemenu::remove(unsigned int index) { 222int Basemenu::remove(unsigned int index) {
223 if (index >= menuitems.size()) { 223 if (index >= menuitems.size()) {
224 #ifdef DEBUG 224#ifdef DEBUG
225 std::cout << "Bad index (" << index << ") given to Basemenu::remove()" 225 std::cout << "Bad index (" << index << ") given to Basemenu::remove()"
226 << " -- should be between 0 and " << menuitems.size()-1 226 << " -- should be between 0 and " << menuitems.size()
227 << " inclusive." 227 << " inclusive." << std::endl;
228 << std::endl; 228#endif // DEBUG
229 #endif
230 return -1; 229 return -1;
231 } 230 }
232 231
diff --git a/src/Workspace.cc b/src/Workspace.cc
index 631fe69..d68e400 100644
--- a/src/Workspace.cc
+++ b/src/Workspace.cc
@@ -22,7 +22,7 @@
22// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER 22// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
23// DEALINGS IN THE SOFTWARE. 23// DEALINGS IN THE SOFTWARE.
24 24
25// $Id: Workspace.cc,v 1.27 2002/09/08 19:38:48 fluxgen Exp $ 25// $Id: Workspace.cc,v 1.28 2002/09/09 10:00:24 fluxgen Exp $
26 26
27#include "Workspace.hh" 27#include "Workspace.hh"
28 28
@@ -164,10 +164,10 @@ int Workspace::removeWindow(FluxboxWindow *w) {
164 w->getTransientFor()->setInputFocus(); 164 w->getTransientFor()->setInputFocus();
165 } else { 165 } else {
166 FluxboxWindow *top = 0; 166 FluxboxWindow *top = 0;
167 if (stackingList.size()!=0) 167 if (stackingList.size() != 0)
168 top = stackingList.front(); 168 top = stackingList.front();
169 169
170 if (!top || !top->setInputFocus()) { 170 if (top == 0|| !top->setInputFocus()) {
171 Fluxbox::instance()->setFocusedWindow(0); // set focused window to none 171 Fluxbox::instance()->setFocusedWindow(0); // set focused window to none
172 XSetInputFocus(Fluxbox::instance()->getXDisplay(), 172 XSetInputFocus(Fluxbox::instance()->getXDisplay(),
173 screen->getToolbar()->getWindowID(), 173 screen->getToolbar()->getWindowID(),
@@ -210,11 +210,7 @@ void Workspace::showAll(void) {
210 WindowStack::iterator it = stackingList.begin(); 210 WindowStack::iterator it = stackingList.begin();
211 WindowStack::iterator it_end = stackingList.end(); 211 WindowStack::iterator it_end = stackingList.end();
212 for (; it != it_end; ++it) { 212 for (; it != it_end; ++it) {
213 if ((*it) == 0) { 213 (*it)->deiconify(false, false);
214 stackingList.erase(it);
215 } else {
216 (*it)->deiconify(False, False);
217 }
218 } 214 }
219} 215}
220 216