Merge branch 'master' into next
This commit is contained in:
commit
2cd8231fce
11
src/main.c
11
src/main.c
@ -432,11 +432,13 @@ int main(int argc, char *argv[]) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
xcb_query_pointer_reply_t *pointerreply;
|
xcb_query_pointer_reply_t *pointerreply;
|
||||||
if (!(pointerreply = xcb_query_pointer_reply(conn, pointercookie, NULL)))
|
Output *output = NULL;
|
||||||
die("Could not query pointer position\n");
|
if (!(pointerreply = xcb_query_pointer_reply(conn, pointercookie, NULL))) {
|
||||||
|
ELOG("Could not query pointer position, using first screen\n");
|
||||||
|
output = get_first_output();
|
||||||
|
} else {
|
||||||
DLOG("Pointer at %d, %d\n", pointerreply->root_x, pointerreply->root_y);
|
DLOG("Pointer at %d, %d\n", pointerreply->root_x, pointerreply->root_y);
|
||||||
Output *output = get_output_containing(pointerreply->root_x, pointerreply->root_y);
|
output = get_output_containing(pointerreply->root_x, pointerreply->root_y);
|
||||||
if (!output) {
|
if (!output) {
|
||||||
ELOG("ERROR: No screen at (%d, %d), starting on the first screen\n",
|
ELOG("ERROR: No screen at (%d, %d), starting on the first screen\n",
|
||||||
pointerreply->root_x, pointerreply->root_y);
|
pointerreply->root_x, pointerreply->root_y);
|
||||||
@ -444,6 +446,7 @@ int main(int argc, char *argv[]) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
con_focus(con_descend_focused(output_get_content(output->con)));
|
con_focus(con_descend_focused(output_get_content(output->con)));
|
||||||
|
}
|
||||||
|
|
||||||
tree_render();
|
tree_render();
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user