Skip to content

Commit

Permalink
clicking on a root window on another screen moves focus to that screen
Browse files Browse the repository at this point in the history
  • Loading branch information
bradleyhughes committed May 3, 2002
1 parent 64ba092 commit ddf3902
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions src/blackbox.cc
Original file line number Diff line number Diff line change
Expand Up @@ -242,6 +242,14 @@ void Blackbox::process_event(XEvent *e) {
for (; it != screenList.end(); ++it) {
if (e->xbutton.window == (*it)->getRootWindow()) {
(*it)->buttonPressEvent(&e->xbutton);

if (active_screen != (*it)) {
active_screen = (*it);
// first, set no focus window on the old screen
setFocusedWindow(0);
// and move focus to this screen
setFocusedWindow(0);
}
break;
}
}
Expand Down

0 comments on commit ddf3902

Please sign in to comment.