1
0
mirror of https://github.com/gryf/wmaker.git synced 2025-12-20 21:08:08 +01:00

wmaker: Moved variable Screen Count into the global namespace

This commit is contained in:
Christophe CURIS
2013-10-10 20:38:21 +02:00
committed by Carlos R. Mafra
parent 6d65daf1be
commit b6423a7b4f
7 changed files with 28 additions and 32 deletions

View File

@@ -78,7 +78,6 @@
/******** Global Variables **********/
extern WShortKey wKeyBindings[WKBD_LAST];
extern int wScreenCount;
#define MOD_MASK wPreferences.modifier_mask
@@ -1198,7 +1197,7 @@ static void handleXkbIndicatorStateNotify(XEvent *event)
XkbStateRec staterec;
int i;
for (i = 0; i < wScreenCount; i++) {
for (i = 0; i < w_global.screen_count; i++) {
scr = wScreenWithNumber(i);
wwin = scr->focused_window;
if (wwin && wwin->flags.focused) {
@@ -1697,17 +1696,17 @@ static void handleKeyPress(XEvent * event)
break;
case WKBD_SWITCH_SCREEN:
if (wScreenCount > 1) {
if (w_global.screen_count > 1) {
WScreen *scr2;
int i;
/* find index of this screen */
for (i = 0; i < wScreenCount; i++) {
for (i = 0; i < w_global.screen_count; i++) {
if (wScreenWithNumber(i) == scr)
break;
}
i++;
if (i >= wScreenCount) {
if (i >= w_global.screen_count) {
i = 0;
}
scr2 = wScreenWithNumber(i);