aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/Ewmh.cc28
-rw-r--r--src/FbCommands.cc10
-rw-r--r--src/Gnome.cc6
3 files changed, 22 insertions, 22 deletions
diff --git a/src/Ewmh.cc b/src/Ewmh.cc
index 7996828..052629d 100644
--- a/src/Ewmh.cc
+++ b/src/Ewmh.cc
@@ -288,8 +288,8 @@ void Ewmh::updateClientList(BScreen &screen) {
288 288
289 } 289 }
290 // and count icons 290 // and count icons
291 BScreen::Icons::const_iterator icon_it = screen.getIconList().begin(); 291 BScreen::Icons::const_iterator icon_it = screen.iconList().begin();
292 BScreen::Icons::const_iterator icon_it_end = screen.getIconList().end(); 292 BScreen::Icons::const_iterator icon_it_end = screen.iconList().end();
293 for (; icon_it != icon_it_end; ++icon_it) { 293 for (; icon_it != icon_it_end; ++icon_it) {
294 num += (*icon_it)->numClients(); 294 num += (*icon_it)->numClients();
295 } 295 }
@@ -327,7 +327,7 @@ void Ewmh::updateClientList(BScreen &screen) {
327 } 327 }
328 328
329 // plus iconified windows 329 // plus iconified windows
330 icon_it = screen.getIconList().begin(); 330 icon_it = screen.iconList().begin();
331 for (; icon_it != icon_it_end; ++icon_it) { 331 for (; icon_it != icon_it_end; ++icon_it) {
332 FluxboxWindow::ClientList::iterator client_it = (*icon_it)->clientList().begin(); 332 FluxboxWindow::ClientList::iterator client_it = (*icon_it)->clientList().begin();
333 FluxboxWindow::ClientList::iterator client_it_end = (*icon_it)->clientList().end(); 333 FluxboxWindow::ClientList::iterator client_it_end = (*icon_it)->clientList().end();
@@ -437,7 +437,7 @@ void Ewmh::updateWorkspaceCount(BScreen &screen) {
437 * Window Manager to indicate the number of virtual 437 * Window Manager to indicate the number of virtual
438 * desktops. 438 * desktops.
439 */ 439 */
440 unsigned long numworkspaces = screen.getCount(); 440 unsigned long numworkspaces = screen.numberOfWorkspaces();
441 screen.rootWindow().changeProperty(m_net_number_of_desktops, 441 screen.rootWindow().changeProperty(m_net_number_of_desktops,
442 XA_CARDINAL, 32, 442 XA_CARDINAL, 32,
443 PropModeReplace, 443 PropModeReplace,
@@ -502,8 +502,8 @@ void Ewmh::updateWorkarea(BScreen &screen) {
502 * Not sure how to handle xinerama stuff here. 502 * Not sure how to handle xinerama stuff here.
503 * So i'm just doing this on the first head. 503 * So i'm just doing this on the first head.
504 */ 504 */
505 unsigned long *coords = new unsigned long[4*screen.getCount()]; 505 unsigned long *coords = new unsigned long[4*screen.numberOfWorkspaces()];
506 for (unsigned int i=0; i<screen.getCount()*4; i+=4) { 506 for (unsigned int i=0; i < screen.numberOfWorkspaces()*4; i+=4) {
507 // x, y 507 // x, y
508 coords[i] = screen.maxLeft(0); 508 coords[i] = screen.maxLeft(0);
509 coords[i + 1] = screen.maxTop(0); 509 coords[i + 1] = screen.maxTop(0);
@@ -516,7 +516,7 @@ void Ewmh::updateWorkarea(BScreen &screen) {
516 XA_CARDINAL, 32, 516 XA_CARDINAL, 32,
517 PropModeReplace, 517 PropModeReplace,
518 (unsigned char *)coords, 518 (unsigned char *)coords,
519 4*screen.getCount()); 519 4 * screen.numberOfWorkspaces());
520 520
521 delete[] coords; 521 delete[] coords;
522} 522}
@@ -638,7 +638,7 @@ bool Ewmh::checkClientMessage(const XClientMessageEvent &ce,
638 // which doesn't apply here (so borrow the variable :) ) 638 // which doesn't apply here (so borrow the variable :) )
639 screen = &fbwin->screen(); 639 screen = &fbwin->screen();
640 // valid workspace number? 640 // valid workspace number?
641 if (static_cast<unsigned int>(ce.data.l[0]) < screen->getCount()) 641 if (static_cast<unsigned int>(ce.data.l[0]) < screen->numberOfWorkspaces())
642 screen->sendToWorkspace(ce.data.l[0], fbwin, false); 642 screen->sendToWorkspace(ce.data.l[0], fbwin, false);
643 643
644 return true; 644 return true;
@@ -668,20 +668,20 @@ bool Ewmh::checkClientMessage(const XClientMessageEvent &ce,
668 668
669 // no need to alter number of desktops if they are the same 669 // no need to alter number of desktops if they are the same
670 // or if requested number of workspace is less than zero 670 // or if requested number of workspace is less than zero
671 if (screen->getCount() == static_cast<unsigned int>(ce.data.l[0]) || 671 if (screen->numberOfWorkspaces() == static_cast<unsigned int>(ce.data.l[0]) ||
672 ce.data.l[0] < 0) 672 ce.data.l[0] < 0)
673 return true; 673 return true;
674 674
675 if (screen->getCount() > static_cast<unsigned int>(ce.data.l[0])) { 675 if (screen->numberOfWorkspaces() > static_cast<unsigned int>(ce.data.l[0])) {
676 // remove last workspace until we have 676 // remove last workspace until we have
677 // the same number of workspaces 677 // the same number of workspaces
678 while (screen->getCount() != static_cast<unsigned int>(ce.data.l[0])) { 678 while (screen->numberOfWorkspaces() != static_cast<unsigned int>(ce.data.l[0])) {
679 screen->removeLastWorkspace(); 679 screen->removeLastWorkspace();
680 if (screen->getCount() == 1) // must have at least one workspace 680 if (screen->numberOfWorkspaces() == 1) // must have at least one workspace
681 break; 681 break;
682 } 682 }
683 } else { // add workspaces to screen until workspace count match the requested size 683 } else { // add workspaces to screen until workspace count match the requested size
684 while (screen->getCount() != static_cast<unsigned int>(ce.data.l[0])) { 684 while (screen->numberOfWorkspaces() != static_cast<unsigned int>(ce.data.l[0])) {
685 screen->addWorkspace(); 685 screen->addWorkspace();
686 } 686 }
687 } 687 }
@@ -693,7 +693,7 @@ bool Ewmh::checkClientMessage(const XClientMessageEvent &ce,
693 // ce.data.l[0] = workspace number 693 // ce.data.l[0] = workspace number
694 694
695 // prevent out of range value 695 // prevent out of range value
696 if (static_cast<unsigned int>(ce.data.l[0]) >= screen->getCount()) 696 if (static_cast<unsigned int>(ce.data.l[0]) >= screen->numberOfWorkspaces())
697 return true; 697 return true;
698 screen->changeWorkspaceID(ce.data.l[0]); 698 screen->changeWorkspaceID(ce.data.l[0]);
699 return true; 699 return true;
diff --git a/src/FbCommands.cc b/src/FbCommands.cc
index fc3f321..cdecc2b 100644
--- a/src/FbCommands.cc
+++ b/src/FbCommands.cc
@@ -61,7 +61,7 @@ namespace {
61void showMenu(const BScreen &screen, FbTk::Menu &menu) { 61void showMenu(const BScreen &screen, FbTk::Menu &menu) {
62 62
63 // special case for root menu 63 // special case for root menu
64 if (&menu == &screen.getRootmenu()) { 64 if (&menu == &screen.rootMenu()) {
65 Fluxbox* fb = Fluxbox::instance(); 65 Fluxbox* fb = Fluxbox::instance();
66 if(fb->menuTimestampsChanged()) { 66 if(fb->menuTimestampsChanged()) {
67 // we dont show the menu here because fluxbox 67 // we dont show the menu here because fluxbox
@@ -221,7 +221,7 @@ void ShowRootMenuCmd::execute() {
221 if (screen == 0) 221 if (screen == 0)
222 return; 222 return;
223 223
224 ::showMenu(*screen, screen->getRootmenu()); 224 ::showMenu(*screen, screen->rootMenu());
225} 225}
226 226
227void ShowWorkspaceMenuCmd::execute() { 227void ShowWorkspaceMenuCmd::execute() {
@@ -229,7 +229,7 @@ void ShowWorkspaceMenuCmd::execute() {
229 if (screen == 0) 229 if (screen == 0)
230 return; 230 return;
231 231
232 ::showMenu(*screen, screen->getWorkspacemenu()); 232 ::showMenu(*screen, screen->workspaceMenu());
233} 233}
234 234
235 235
@@ -324,8 +324,8 @@ void DeiconifyCmd::execute() {
324 if (screen == 0) 324 if (screen == 0)
325 return; 325 return;
326 326
327 BScreen::Icons::reverse_iterator it= screen->getIconList().rbegin(); 327 BScreen::Icons::reverse_iterator it= screen->iconList().rbegin();
328 BScreen::Icons::reverse_iterator itend= screen->getIconList().rend(); 328 BScreen::Icons::reverse_iterator itend= screen->iconList().rend();
329 unsigned int workspace_num= screen->currentWorkspaceID(); 329 unsigned int workspace_num= screen->currentWorkspaceID();
330 unsigned int old_workspace_num; 330 unsigned int old_workspace_num;
331 331
diff --git a/src/Gnome.cc b/src/Gnome.cc
index 1691c9e..59cbc0a 100644
--- a/src/Gnome.cc
+++ b/src/Gnome.cc
@@ -234,7 +234,7 @@ void Gnome::updateCurrentWorkspace(BScreen &screen) {
234} 234}
235 235
236void Gnome::updateWorkspaceCount(BScreen &screen) { 236void Gnome::updateWorkspaceCount(BScreen &screen) {
237 long numworkspaces = screen.getCount(); 237 long numworkspaces = screen.numberOfWorkspaces();
238 screen.rootWindow().changeProperty(m_gnome_wm_win_workspace_count, XA_CARDINAL, 32, PropModeReplace, 238 screen.rootWindow().changeProperty(m_gnome_wm_win_workspace_count, XA_CARDINAL, 32, PropModeReplace,
239 (unsigned char *)&numworkspaces, 1); 239 (unsigned char *)&numworkspaces, 1);
240} 240}
@@ -302,12 +302,12 @@ bool Gnome::checkClientMessage(const XClientMessageEvent &ce, BScreen * screen,
302#endif//!DEBUG 302#endif//!DEBUG
303 if ( winclient !=0 && // the message sent to client window? 303 if ( winclient !=0 && // the message sent to client window?
304 ce.data.l[0] >= 0 && 304 ce.data.l[0] >= 0 &&
305 ce.data.l[0] < (signed)winclient->screen().getCount()) { 305 ce.data.l[0] < (signed)winclient->screen().numberOfWorkspaces()) {
306 winclient->screen().changeWorkspaceID(ce.data.l[0]); 306 winclient->screen().changeWorkspaceID(ce.data.l[0]);
307 307
308 } else if (screen!=0 && //the message sent to root window? 308 } else if (screen!=0 && //the message sent to root window?
309 ce.data.l[0] >= 0 && 309 ce.data.l[0] >= 0 &&
310 ce.data.l[0] < (signed)screen->getCount()) 310 ce.data.l[0] < (signed)screen->numberOfWorkspaces())
311 screen->changeWorkspaceID(ce.data.l[0]); 311 screen->changeWorkspaceID(ce.data.l[0]);
312 return true; 312 return true;
313 } else if (winclient == 0) 313 } else if (winclient == 0)