diff options
Diffstat (limited to 'src/manage.c')
-rw-r--r-- | src/manage.c | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/src/manage.c b/src/manage.c index 059c480..f66f723 100644 --- a/src/manage.c +++ b/src/manage.c @@ -64,7 +64,16 @@ ungrab_prefix_key (Window w) screen_info* current_screen () { - return &screens[rp_current_screen]; + int i; + + for (i=0; i<num_screens; i++) + { + if (screens[i].screen_num == rp_current_screen) + return &screens[i]; + } + + /* This should never happen. */ + return &screens[0]; } void |