aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/Workspace.cc18
-rw-r--r--src/Workspace.hh4
2 files changed, 15 insertions, 7 deletions
diff --git a/src/Workspace.cc b/src/Workspace.cc
index 8f0433f..3a2697e 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.10 2002/02/10 19:05:12 fluxgen Exp $ 25// $Id: Workspace.cc,v 1.11 2002/02/16 11:28:16 fluxgen Exp $
26 26
27// use GNU extensions 27// use GNU extensions
28#ifndef _GNU_SOURCE 28#ifndef _GNU_SOURCE
@@ -58,6 +58,11 @@
58#include <iostream> 58#include <iostream>
59using namespace std; 59using namespace std;
60 60
61#ifdef DEBUG
62#include <iostream>
63using namespace std;
64#endif
65
61Workspace::Workspace(BScreen *scrn, int i): 66Workspace::Workspace(BScreen *scrn, int i):
62screen(scrn), 67screen(scrn),
63lastfocus(0), 68lastfocus(0),
@@ -295,12 +300,12 @@ void Workspace::update(void) {
295} 300}
296 301
297 302
298Bool Workspace::isCurrent(void) { 303bool Workspace::isCurrent(void) {
299 return (id == screen->getCurrentWorkspaceID()); 304 return (id == screen->getCurrentWorkspaceID());
300} 305}
301 306
302 307
303Bool Workspace::isLastWindow(FluxboxWindow *w) { 308bool Workspace::isLastWindow(FluxboxWindow *w) {
304 return (w == windowList.back()); 309 return (w == windowList.back());
305} 310}
306 311
@@ -332,14 +337,17 @@ void Workspace::setName(char *new_name) {
332 clientmenu->update(); 337 clientmenu->update();
333} 338}
334 339
335 340//------------ shutdown ---------
341// Calles restore on all windows
342// in the workspace and then
343// clears the windowList
344//-------------------------------
336void Workspace::shutdown(void) { 345void Workspace::shutdown(void) {
337 346
338 while (!windowList.empty()) { 347 while (!windowList.empty()) {
339 windowList.back()->restore(); 348 windowList.back()->restore();
340 delete windowList.back(); //delete window (the window removes it self from windowList) 349 delete windowList.back(); //delete window (the window removes it self from windowList)
341 } 350 }
342
343} 351}
344 352
345 353
diff --git a/src/Workspace.hh b/src/Workspace.hh
index 08c5ad9..0c76f0c 100644
--- a/src/Workspace.hh
+++ b/src/Workspace.hh
@@ -71,8 +71,8 @@ public:
71 71
72 FluxboxWindow *getWindow(int); 72 FluxboxWindow *getWindow(int);
73 73
74 Bool isCurrent(void); 74 bool isCurrent(void);
75 Bool isLastWindow(FluxboxWindow *); 75 bool isLastWindow(FluxboxWindow *);
76 76
77 const int addWindow(FluxboxWindow *, Bool = False); 77 const int addWindow(FluxboxWindow *, Bool = False);
78 const int removeWindow(FluxboxWindow *); 78 const int removeWindow(FluxboxWindow *);