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,
|
void _clutter_actor_set_has_pointer (ClutterActor *self,
|
||||||
gboolean has_pointer);
|
gboolean has_pointer);
|
||||||
|
|
||||||
void _clutter_actor_queue_redraw_with_clip (ClutterActor *self,
|
void _clutter_actor_queue_redraw_with_clip (ClutterActor *self,
|
||||||
ClutterRedrawFlags flags,
|
ClutterRedrawFlags flags,
|
||||||
ClutterPaintVolume *clip_volume);
|
const ClutterPaintVolume *clip_volume);
|
||||||
void _clutter_actor_queue_redraw_full (ClutterActor *self,
|
void _clutter_actor_queue_redraw_full (ClutterActor *self,
|
||||||
ClutterRedrawFlags flags,
|
ClutterRedrawFlags flags,
|
||||||
ClutterPaintVolume *volume,
|
const ClutterPaintVolume *volume,
|
||||||
ClutterEffect *effect);
|
ClutterEffect *effect);
|
||||||
|
|
||||||
ClutterPaintVolume * _clutter_actor_get_queue_redraw_clip (ClutterActor *self);
|
ClutterPaintVolume * _clutter_actor_get_queue_redraw_clip (ClutterActor *self);
|
||||||
void _clutter_actor_set_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
|
void
|
||||||
_clutter_actor_queue_redraw_full (ClutterActor *self,
|
_clutter_actor_queue_redraw_full (ClutterActor *self,
|
||||||
ClutterRedrawFlags flags,
|
ClutterRedrawFlags flags,
|
||||||
ClutterPaintVolume *volume,
|
const ClutterPaintVolume *volume,
|
||||||
ClutterEffect *effect)
|
ClutterEffect *effect)
|
||||||
{
|
{
|
||||||
ClutterActorPrivate *priv = self->priv;
|
ClutterActorPrivate *priv = self->priv;
|
||||||
ClutterPaintVolume allocation_pv;
|
ClutterPaintVolume allocation_pv;
|
||||||
ClutterPaintVolume *pv;
|
ClutterPaintVolume *pv = NULL;
|
||||||
gboolean should_free_pv;
|
|
||||||
ClutterActor *stage;
|
ClutterActor *stage;
|
||||||
|
|
||||||
/* Here's an outline of the actor queue redraw mechanism:
|
/* 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,
|
clutter_paint_volume_set_height (pv,
|
||||||
allocation_clip.y2 -
|
allocation_clip.y2 -
|
||||||
allocation_clip.y1);
|
allocation_clip.y1);
|
||||||
should_free_pv = TRUE;
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
pv = volume;
|
|
||||||
should_free_pv = FALSE;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
self->priv->queue_redraw_entry =
|
self->priv->queue_redraw_entry =
|
||||||
_clutter_stage_queue_actor_redraw (CLUTTER_STAGE (stage),
|
_clutter_stage_queue_actor_redraw (CLUTTER_STAGE (stage),
|
||||||
priv->queue_redraw_entry,
|
priv->queue_redraw_entry,
|
||||||
self,
|
self,
|
||||||
pv);
|
pv ? pv : volume);
|
||||||
|
|
||||||
if (should_free_pv)
|
if (pv)
|
||||||
clutter_paint_volume_free (pv);
|
clutter_paint_volume_free (pv);
|
||||||
|
|
||||||
/* If this is the first redraw queued then we can directly use the
|
/* 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.
|
* picking of your actor.
|
||||||
*/
|
*/
|
||||||
void
|
void
|
||||||
_clutter_actor_queue_redraw_with_clip (ClutterActor *self,
|
_clutter_actor_queue_redraw_with_clip (ClutterActor *self,
|
||||||
ClutterRedrawFlags flags,
|
ClutterRedrawFlags flags,
|
||||||
ClutterPaintVolume *volume)
|
const ClutterPaintVolume *volume)
|
||||||
{
|
{
|
||||||
_clutter_actor_queue_redraw_full (self,
|
_clutter_actor_queue_redraw_full (self,
|
||||||
flags, /* flags */
|
flags, /* flags */
|
||||||
|
@ -87,7 +87,7 @@ const ClutterPlane *_clutter_stage_get_clip (ClutterStage *stage);
|
|||||||
ClutterStageQueueRedrawEntry *_clutter_stage_queue_actor_redraw (ClutterStage *stage,
|
ClutterStageQueueRedrawEntry *_clutter_stage_queue_actor_redraw (ClutterStage *stage,
|
||||||
ClutterStageQueueRedrawEntry *entry,
|
ClutterStageQueueRedrawEntry *entry,
|
||||||
ClutterActor *actor,
|
ClutterActor *actor,
|
||||||
ClutterPaintVolume *clip);
|
const ClutterPaintVolume *clip);
|
||||||
void _clutter_stage_queue_redraw_entry_invalidate (ClutterStageQueueRedrawEntry *entry);
|
void _clutter_stage_queue_redraw_entry_invalidate (ClutterStageQueueRedrawEntry *entry);
|
||||||
|
|
||||||
CoglFramebuffer *_clutter_stage_get_active_framebuffer (ClutterStage *stage);
|
CoglFramebuffer *_clutter_stage_get_active_framebuffer (ClutterStage *stage);
|
||||||
|
@ -4145,10 +4145,10 @@ _clutter_stage_get_clip (ClutterStage *stage)
|
|||||||
* didn't explicitly do so.
|
* didn't explicitly do so.
|
||||||
*/
|
*/
|
||||||
ClutterStageQueueRedrawEntry *
|
ClutterStageQueueRedrawEntry *
|
||||||
_clutter_stage_queue_actor_redraw (ClutterStage *stage,
|
_clutter_stage_queue_actor_redraw (ClutterStage *stage,
|
||||||
ClutterStageQueueRedrawEntry *entry,
|
ClutterStageQueueRedrawEntry *entry,
|
||||||
ClutterActor *actor,
|
ClutterActor *actor,
|
||||||
ClutterPaintVolume *clip)
|
const ClutterPaintVolume *clip)
|
||||||
{
|
{
|
||||||
ClutterStagePrivate *priv = stage->priv;
|
ClutterStagePrivate *priv = stage->priv;
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user