mirror of
https://github.com/brl/mutter.git
synced 2024-11-21 23:50:41 -05:00
renderer: Change 'set_legacy_view()' to 'add_view()'
"Legacy" is a misleading name, it's just how the native backend and the X11 backend behaves differently. Instead rename it to 'add_view()' and add the sanity check to the caller. https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/1251
This commit is contained in:
parent
7343b8d817
commit
73a436362a
@ -160,14 +160,12 @@ meta_renderer_real_rebuild_views (MetaRenderer *renderer)
|
|||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
meta_renderer_set_legacy_view (MetaRenderer *renderer,
|
meta_renderer_add_view (MetaRenderer *renderer,
|
||||||
MetaRendererView *legacy_view)
|
MetaRendererView *view)
|
||||||
{
|
{
|
||||||
MetaRendererPrivate *priv = meta_renderer_get_instance_private (renderer);
|
MetaRendererPrivate *priv = meta_renderer_get_instance_private (renderer);
|
||||||
|
|
||||||
g_assert (!priv->views);
|
priv->views = g_list_append (priv->views, view);
|
||||||
|
|
||||||
priv->views = g_list_append (priv->views, legacy_view);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -54,8 +54,8 @@ CoglRenderer * meta_renderer_create_cogl_renderer (MetaRenderer *renderer);
|
|||||||
|
|
||||||
void meta_renderer_rebuild_views (MetaRenderer *renderer);
|
void meta_renderer_rebuild_views (MetaRenderer *renderer);
|
||||||
|
|
||||||
void meta_renderer_set_legacy_view (MetaRenderer *renderer,
|
void meta_renderer_add_view (MetaRenderer *renderer,
|
||||||
MetaRendererView *legacy_view);
|
MetaRendererView *view);
|
||||||
|
|
||||||
META_EXPORT_TEST
|
META_EXPORT_TEST
|
||||||
GList * meta_renderer_get_views (MetaRenderer *renderer);
|
GList * meta_renderer_get_views (MetaRenderer *renderer);
|
||||||
|
@ -167,7 +167,8 @@ meta_renderer_x11_nested_ensure_legacy_view (MetaRendererX11Nested *renderer_x11
|
|||||||
"framebuffer", COGL_FRAMEBUFFER (fake_onscreen),
|
"framebuffer", COGL_FRAMEBUFFER (fake_onscreen),
|
||||||
NULL);
|
NULL);
|
||||||
|
|
||||||
meta_renderer_set_legacy_view (renderer, legacy_view);
|
g_assert (!meta_renderer_get_views (renderer));
|
||||||
|
meta_renderer_add_view (renderer, legacy_view);
|
||||||
}
|
}
|
||||||
|
|
||||||
static MetaRendererView *
|
static MetaRendererView *
|
||||||
|
Loading…
Reference in New Issue
Block a user