clients/scaler: check viewporter availability
I just got bitten by this: I thought my compositor was dropping the viewport somehow, but it just didn't expose the viewporter global. Signed-off-by: Simon Ser <contact@emersion.fr>
This commit is contained in:
parent
8ca6c24c8f
commit
fe49534488
|
@ -317,6 +317,11 @@ main(int argc, char *argv[])
|
||||||
display_set_user_data(box.display, &box);
|
display_set_user_data(box.display, &box);
|
||||||
display_set_global_handler(box.display, global_handler);
|
display_set_global_handler(box.display, global_handler);
|
||||||
|
|
||||||
|
if (box.mode != MODE_NO_VIEWPORT && !box.viewport) {
|
||||||
|
fprintf(stderr, "compositor doesn't support viewporter\n");
|
||||||
|
return -1;
|
||||||
|
}
|
||||||
|
|
||||||
display_run(d);
|
display_run(d);
|
||||||
|
|
||||||
widget_destroy(box.widget);
|
widget_destroy(box.widget);
|
||||||
|
|
Loading…
Reference in New Issue