summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorfluxgen <fluxgen>2002-01-21 02:10:25 (GMT)
committerfluxgen <fluxgen>2002-01-21 02:10:25 (GMT)
commitb3427664c47380e7e9061c23718be70eecc59db2 (patch)
tree030220228638e5aee4d1efb47cf429713c8ff343
parentca75fd7960534ae26f24aa5b9bce9c0b05a3911a (diff)
downloadfluxbox_lack-b3427664c47380e7e9061c23718be70eecc59db2.zip
fluxbox_lack-b3427664c47380e7e9061c23718be70eecc59db2.tar.bz2
Fixed update of workspaces and some indentation
-rw-r--r--src/Screen.cc24
1 files changed, 11 insertions, 13 deletions
diff --git a/src/Screen.cc b/src/Screen.cc
index 60914ef..8d50043 100644
--- a/src/Screen.cc
+++ b/src/Screen.cc
@@ -86,10 +86,6 @@
86# include <stdarg.h> 86# include <stdarg.h>
87#endif // HAVE_STDARG_H 87#endif // HAVE_STDARG_H
88 88
89#ifndef HAVE_SNPRINTF
90# include "bsd-snprintf.h"
91#endif // !HAVE_SNPRINTF
92
93#ifndef MAXPATHLEN 89#ifndef MAXPATHLEN
94#define MAXPATHLEN 255 90#define MAXPATHLEN 255
95#endif // MAXPATHLEN 91#endif // MAXPATHLEN
@@ -210,6 +206,8 @@ full_max(rm, true, scrname+".fullMaximization", altscrname+".FullMaximization"),
210max_over_slit(rm, true, scrname+".maxOverSlit",altscrname+".MaxOverSlit"), 206max_over_slit(rm, true, scrname+".maxOverSlit",altscrname+".MaxOverSlit"),
211tab_rotate_vertical(rm, true, scrname+".tab.rotatevertical", altscrname+".Tab.RotateVertical"), 207tab_rotate_vertical(rm, true, scrname+".tab.rotatevertical", altscrname+".Tab.RotateVertical"),
212sloppy_window_grouping(rm, true, scrname+".sloppywindowgrouping", altscrname+".SloppyWindowGrouping"), 208sloppy_window_grouping(rm, true, scrname+".sloppywindowgrouping", altscrname+".SloppyWindowGrouping"),
209focus_last(rm, true, scrname+".focusLastWindow", altscrname+".FocusLastWindow"),
210focus_new(rm, true, scrname+".focusNewWindows", altscrname+".FocusNewWindows"),
213rootcommand(rm, "", scrname+".rootCommand", altscrname+".RootCommand"), 211rootcommand(rm, "", scrname+".rootCommand", altscrname+".RootCommand"),
214workspaces(rm, 1, scrname+".workspaces", altscrname+".Workspaces"), 212workspaces(rm, 1, scrname+".workspaces", altscrname+".Workspaces"),
215toolbar_width_percent(rm, 65, scrname+".toolbar.widthPercent", altscrname+".Toolbar.WidthPercent"), 213toolbar_width_percent(rm, 65, scrname+".toolbar.widthPercent", altscrname+".Toolbar.WidthPercent"),
@@ -269,9 +267,9 @@ resource(rm, screenname, altscreenname)
269 pid_t bpid = getpid(); 267 pid_t bpid = getpid();
270 268
271 XChangeProperty(getBaseDisplay()->getXDisplay(), getRootWindow(), 269 XChangeProperty(getBaseDisplay()->getXDisplay(), getRootWindow(),
272 fluxbox->getFluxboxPidAtom(), XA_CARDINAL, 270 fluxbox->getFluxboxPidAtom(), XA_CARDINAL,
273 sizeof(pid_t) * 8, PropModeReplace, 271 sizeof(pid_t) * 8, PropModeReplace,
274 (unsigned char *) &bpid, 1); 272 (unsigned char *) &bpid, 1);
275 #endif // HAVE_GETPID 273 #endif // HAVE_GETPID
276 274
277 275
@@ -286,7 +284,7 @@ resource(rm, screenname, altscreenname)
286 284
287 image_control = 285 image_control =
288 new BImageControl(fluxbox, this, True, fluxbox->getColorsPerChannel(), 286 new BImageControl(fluxbox, this, True, fluxbox->getColorsPerChannel(),
289 fluxbox->getCacheLife(), fluxbox->getCacheMax()); 287 fluxbox->getCacheLife(), fluxbox->getCacheMax());
290 image_control->installRootColormap(); 288 image_control->installRootColormap();
291 root_colormap_installed = True; 289 root_colormap_installed = True;
292 290
@@ -474,7 +472,7 @@ resource(rm, screenname, altscreenname)
474 delete tempwin; 472 delete tempwin;
475 tempwin = 0; 473 tempwin = 0;
476 } catch (...) { 474 } catch (...) {
477 cerr<<"FATAL: Unknown catch"<<endl; 475 cerr<<"FATAL: Unknown exception"<<endl;
478 } 476 }
479 477
480 FluxboxWindow *win = fluxbox->searchWindow(children[i]); 478 FluxboxWindow *win = fluxbox->searchWindow(children[i]);
@@ -731,9 +729,9 @@ int BScreen::addWorkspace(void) {
731 workspacesList->insert(wkspc); 729 workspacesList->insert(wkspc);
732 730
733 workspacemenu->insert(wkspc->getName(), wkspc->getMenu(), 731 workspacemenu->insert(wkspc->getName(), wkspc->getMenu(),
734 wkspc->getWorkspaceID() + 1); 732 wkspc->getWorkspaceID() + 1);
735 workspacemenu->update(); 733 workspacemenu->update();
736 734 saveWorkspaces(workspacesList->count());
737 toolbar->reconfigure(); 735 toolbar->reconfigure();
738 736
739 updateNetizenWorkspaceCount(); 737 updateNetizenWorkspaceCount();
@@ -762,7 +760,7 @@ int BScreen::removeLastWorkspace(void) {
762 toolbar->reconfigure(); 760 toolbar->reconfigure();
763 761
764 updateNetizenWorkspaceCount(); 762 updateNetizenWorkspaceCount();
765 763 saveWorkspaces(workspacesList->count());
766 return workspacesList->count(); 764 return workspacesList->count();
767 } 765 }
768 766
@@ -799,7 +797,7 @@ void BScreen::changeWorkspaceID(int id) {
799 797
800 current_workspace->showAll(); 798 current_workspace->showAll();
801 799
802 if (resource.focus_last && current_workspace->getLastFocusedWindow()) 800 if (*resource.focus_last && current_workspace->getLastFocusedWindow())
803 current_workspace->getLastFocusedWindow()->setInputFocus(); 801 current_workspace->getLastFocusedWindow()->setInputFocus();
804 802
805 } 803 }