[mutter/wip/carlosg/reuse-paint-volumes: 58/59] compositor: Add get_paint_volume() implementation to MetaSurfaceActor
- From: Florian Müllner <fmuellner src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [mutter/wip/carlosg/reuse-paint-volumes: 58/59] compositor: Add get_paint_volume() implementation to MetaSurfaceActor
- Date: Fri, 13 Jul 2018 11:43:41 +0000 (UTC)
commit 94f400988220eae76a1fb30390a62104da8f7b8f
Author: Carlos Garnacho <carlosg gnome org>
Date: Sat Apr 28 18:14:34 2018 +0200
compositor: Add get_paint_volume() implementation to MetaSurfaceActor
The special ::pick implementation there makes clutter fall into paths
that do require a get_paint_volume() implementation, or an infinite
area will be used.
Providing a paint volume here is easier on the invalidation mechanism.
src/compositor/meta-surface-actor.c | 8 ++++++++
1 file changed, 8 insertions(+)
---
diff --git a/src/compositor/meta-surface-actor.c b/src/compositor/meta-surface-actor.c
index bf8c76f39..9acfab1f0 100644
--- a/src/compositor/meta-surface-actor.c
+++ b/src/compositor/meta-surface-actor.c
@@ -101,6 +101,13 @@ meta_surface_actor_pick (ClutterActor *actor,
clutter_actor_paint (child);
}
+static gboolean
+meta_surface_actor_get_paint_volume (ClutterActor *actor,
+ ClutterPaintVolume *volume)
+{
+ return clutter_paint_volume_set_from_allocation (volume, actor);
+}
+
static void
meta_surface_actor_dispose (GObject *object)
{
@@ -120,6 +127,7 @@ meta_surface_actor_class_init (MetaSurfaceActorClass *klass)
object_class->dispose = meta_surface_actor_dispose;
actor_class->pick = meta_surface_actor_pick;
+ actor_class->get_paint_volume = meta_surface_actor_get_paint_volume;
signals[REPAINT_SCHEDULED] = g_signal_new ("repaint-scheduled",
G_TYPE_FROM_CLASS (object_class),
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]