clutter: Make paint volume argument const on queue_redraw*()
The given paint volume is actually unmodified, there is no need to require non-const arguments when some getters actually give const paint volumes.
This commit is contained in:
parent
9004253c4e
commit
9a843857b3
@ -275,13 +275,13 @@ void _clutter_actor_set_enable_paint_unmapped
|
||||
void _clutter_actor_set_has_pointer (ClutterActor *self,
|
||||
gboolean has_pointer);
|
||||
|
||||
void _clutter_actor_queue_redraw_with_clip (ClutterActor *self,
|
||||
ClutterRedrawFlags flags,
|
||||
ClutterPaintVolume *clip_volume);
|
||||
void _clutter_actor_queue_redraw_full (ClutterActor *self,
|
||||
ClutterRedrawFlags flags,
|
||||
ClutterPaintVolume *volume,
|
||||
ClutterEffect *effect);
|
||||
void _clutter_actor_queue_redraw_with_clip (ClutterActor *self,
|
||||
ClutterRedrawFlags flags,
|
||||
const ClutterPaintVolume *clip_volume);
|
||||
void _clutter_actor_queue_redraw_full (ClutterActor *self,
|
||||
ClutterRedrawFlags flags,
|
||||
const ClutterPaintVolume *volume,
|
||||
ClutterEffect *effect);
|
||||
|
||||
ClutterPaintVolume * _clutter_actor_get_queue_redraw_clip (ClutterActor *self);
|
||||
void _clutter_actor_set_queue_redraw_clip (ClutterActor *self,
|
||||
|
@ -8744,15 +8744,14 @@ _clutter_actor_get_allocation_clip (ClutterActor *self,
|
||||
}
|
||||
|
||||
void
|
||||
_clutter_actor_queue_redraw_full (ClutterActor *self,
|
||||
ClutterRedrawFlags flags,
|
||||
ClutterPaintVolume *volume,
|
||||
ClutterEffect *effect)
|
||||
_clutter_actor_queue_redraw_full (ClutterActor *self,
|
||||
ClutterRedrawFlags flags,
|
||||
const ClutterPaintVolume *volume,
|
||||
ClutterEffect *effect)
|
||||
{
|
||||
ClutterActorPrivate *priv = self->priv;
|
||||
ClutterPaintVolume allocation_pv;
|
||||
ClutterPaintVolume *pv;
|
||||
gboolean should_free_pv;
|
||||
ClutterPaintVolume *pv = NULL;
|
||||
ClutterActor *stage;
|
||||
|
||||
/* Here's an outline of the actor queue redraw mechanism:
|
||||
@ -8894,21 +8893,15 @@ _clutter_actor_queue_redraw_full (ClutterActor *self,
|
||||
clutter_paint_volume_set_height (pv,
|
||||
allocation_clip.y2 -
|
||||
allocation_clip.y1);
|
||||
should_free_pv = TRUE;
|
||||
}
|
||||
else
|
||||
{
|
||||
pv = volume;
|
||||
should_free_pv = FALSE;
|
||||
}
|
||||
|
||||
self->priv->queue_redraw_entry =
|
||||
_clutter_stage_queue_actor_redraw (CLUTTER_STAGE (stage),
|
||||
priv->queue_redraw_entry,
|
||||
self,
|
||||
pv);
|
||||
pv ? pv : volume);
|
||||
|
||||
if (should_free_pv)
|
||||
if (pv)
|
||||
clutter_paint_volume_free (pv);
|
||||
|
||||
/* If this is the first redraw queued then we can directly use the
|
||||
@ -9022,9 +9015,9 @@ clutter_actor_queue_redraw (ClutterActor *self)
|
||||
* picking of your actor.
|
||||
*/
|
||||
void
|
||||
_clutter_actor_queue_redraw_with_clip (ClutterActor *self,
|
||||
ClutterRedrawFlags flags,
|
||||
ClutterPaintVolume *volume)
|
||||
_clutter_actor_queue_redraw_with_clip (ClutterActor *self,
|
||||
ClutterRedrawFlags flags,
|
||||
const ClutterPaintVolume *volume)
|
||||
{
|
||||
_clutter_actor_queue_redraw_full (self,
|
||||
flags, /* flags */
|
||||
|
@ -87,7 +87,7 @@ const ClutterPlane *_clutter_stage_get_clip (ClutterStage *stage);
|
||||
ClutterStageQueueRedrawEntry *_clutter_stage_queue_actor_redraw (ClutterStage *stage,
|
||||
ClutterStageQueueRedrawEntry *entry,
|
||||
ClutterActor *actor,
|
||||
ClutterPaintVolume *clip);
|
||||
const ClutterPaintVolume *clip);
|
||||
void _clutter_stage_queue_redraw_entry_invalidate (ClutterStageQueueRedrawEntry *entry);
|
||||
|
||||
CoglFramebuffer *_clutter_stage_get_active_framebuffer (ClutterStage *stage);
|
||||
|
@ -4145,10 +4145,10 @@ _clutter_stage_get_clip (ClutterStage *stage)
|
||||
* didn't explicitly do so.
|
||||
*/
|
||||
ClutterStageQueueRedrawEntry *
|
||||
_clutter_stage_queue_actor_redraw (ClutterStage *stage,
|
||||
_clutter_stage_queue_actor_redraw (ClutterStage *stage,
|
||||
ClutterStageQueueRedrawEntry *entry,
|
||||
ClutterActor *actor,
|
||||
ClutterPaintVolume *clip)
|
||||
ClutterActor *actor,
|
||||
const ClutterPaintVolume *clip)
|
||||
{
|
||||
ClutterStagePrivate *priv = stage->priv;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user