From 2c1ab8b3ccddd73572700d50e7b190c8de448adc Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jonas=20=C3=85dahl?= Date: Tue, 12 Feb 2019 11:25:45 +0100 Subject: [PATCH] renderer/native: Remove legacy non-stage-view code A renderer view will, under the native backend, since long ago always have a logical monitor associated with it, so remove the code handling the legacy non-stage view case. https://gitlab.gnome.org/GNOME/mutter/issues/460 --- src/backends/native/meta-renderer-native.c | 31 ++++------------------ 1 file changed, 5 insertions(+), 26 deletions(-) diff --git a/src/backends/native/meta-renderer-native.c b/src/backends/native/meta-renderer-native.c index 5813a41b8..d6199e0d0 100644 --- a/src/backends/native/meta-renderer-native.c +++ b/src/backends/native/meta-renderer-native.c @@ -1704,7 +1704,6 @@ meta_onscreen_native_flip_crtcs (CoglOnscreen *onscreen) { CoglOnscreenEGL *onscreen_egl = onscreen->winsys; MetaOnscreenNative *onscreen_native = onscreen_egl->platform; - MetaGpuKms *render_gpu = onscreen_native->render_gpu; MetaRendererView *view = onscreen_native->view; GClosure *flip_closure; MetaLogicalMonitor *logical_monitor; @@ -1728,32 +1727,12 @@ meta_onscreen_native_flip_crtcs (CoglOnscreen *onscreen) /* Either flip the CRTC's of the monitor info, if we are drawing just part * of the stage, or all of the CRTC's if we are drawing the whole stage. */ + FlipCrtcData data = { + .onscreen = onscreen, + .flip_closure = flip_closure, + }; logical_monitor = meta_renderer_view_get_logical_monitor (view); - if (logical_monitor) - { - FlipCrtcData data = { - .onscreen = onscreen, - .flip_closure = flip_closure, - }; - - meta_logical_monitor_foreach_crtc (logical_monitor, - flip_crtc, - &data); - fb_in_use = data.out_fb_in_use; - } - else - { - GList *l; - - for (l = meta_gpu_get_crtcs (META_GPU (render_gpu)); l; l = l->next) - { - MetaCrtc *crtc = l->data; - - meta_onscreen_native_flip_crtc (onscreen, flip_closure, - crtc, crtc->rect.x, crtc->rect.y, - &fb_in_use); - } - } + meta_logical_monitor_foreach_crtc (logical_monitor, flip_crtc, &data); /* * If the framebuffer is in use, but we don't have any pending flips it means