mirror of
https://github.com/brl/mutter.git
synced 2025-02-16 21:34:09 +00:00
x11/stage: Remove CLUTTER_SCALE handling
Use the ClutterSettings:window-scaling-factor property instead. https://bugzilla.gnome.org/show_bug.cgi?id=705915
This commit is contained in:
parent
afd87abb70
commit
2c8a19b8c1
@ -822,9 +822,6 @@ clutter_stage_x11_set_scale_factor (ClutterStageWindow *stage_window,
|
|||||||
{
|
{
|
||||||
ClutterStageX11 *stage_x11 = CLUTTER_STAGE_X11 (stage_window);
|
ClutterStageX11 *stage_x11 = CLUTTER_STAGE_X11 (stage_window);
|
||||||
|
|
||||||
if (stage_x11->fixed_scale_factor)
|
|
||||||
return;
|
|
||||||
|
|
||||||
stage_x11->scale_factor = factor;
|
stage_x11->scale_factor = factor;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -869,8 +866,6 @@ clutter_stage_x11_class_init (ClutterStageX11Class *klass)
|
|||||||
static void
|
static void
|
||||||
clutter_stage_x11_init (ClutterStageX11 *stage)
|
clutter_stage_x11_init (ClutterStageX11 *stage)
|
||||||
{
|
{
|
||||||
const char *scale_str;
|
|
||||||
|
|
||||||
stage->xwin = None;
|
stage->xwin = None;
|
||||||
stage->xwin_width = 640;
|
stage->xwin_width = 640;
|
||||||
stage->xwin_height = 480;
|
stage->xwin_height = 480;
|
||||||
@ -884,19 +879,11 @@ clutter_stage_x11_init (ClutterStageX11 *stage)
|
|||||||
|
|
||||||
stage->title = NULL;
|
stage->title = NULL;
|
||||||
|
|
||||||
scale_str = g_getenv ("CLUTTER_SCALE");
|
g_object_get (clutter_settings_get_default (),
|
||||||
if (scale_str != NULL)
|
"window-scaling-factor", &stage->scale_factor,
|
||||||
{
|
NULL);
|
||||||
CLUTTER_NOTE (BACKEND, "Scale factor set using environment variable: %d ('%s')",
|
stage->xwin_width *= stage->scale_factor;
|
||||||
atol (scale_str),
|
stage->xwin_height *= stage->scale_factor;
|
||||||
scale_str);
|
|
||||||
stage->fixed_scale_factor = TRUE;
|
|
||||||
stage->scale_factor = atol (scale_str);
|
|
||||||
stage->xwin_width *= stage->scale_factor;
|
|
||||||
stage->xwin_height *= stage->scale_factor;
|
|
||||||
}
|
|
||||||
else
|
|
||||||
stage->scale_factor = 1;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
static void
|
static void
|
||||||
|
@ -69,7 +69,6 @@ struct _ClutterStageX11
|
|||||||
guint viewport_initialized : 1;
|
guint viewport_initialized : 1;
|
||||||
guint accept_focus : 1;
|
guint accept_focus : 1;
|
||||||
guint fullscreen_on_realize : 1;
|
guint fullscreen_on_realize : 1;
|
||||||
guint fixed_scale_factor : 1;
|
|
||||||
};
|
};
|
||||||
|
|
||||||
struct _ClutterStageX11Class
|
struct _ClutterStageX11Class
|
||||||
|
Loading…
x
Reference in New Issue
Block a user