run-js-test: fix running in hi-dpi mode

This commit is contained in:
Owen W. Taylor 2015-10-27 15:51:13 -04:00
parent c6eb95ff3a
commit c4584c20dc

View File

@ -59,6 +59,8 @@ main(int argc, char **argv)
gsize len;
int code;
gdk_set_allowed_backends("x11");
gtk_init (&argc, &argv);
clutter_x11_set_display (GDK_DISPLAY_XDISPLAY (gdk_display_get_default ()));
@ -66,6 +68,9 @@ main(int argc, char **argv)
if (clutter_init (&argc, &argv) != CLUTTER_INIT_SUCCESS)
return 1;
g_object_set (clutter_settings_get_default (), "window-scaling-factor", 1, NULL);
gdk_x11_display_set_window_scale (gdk_display_get_default (), 1);
context = g_option_context_new (NULL);
/* pass unknown through to the JS script */