[mutter/wip/rstrode/rhel-8.0.0: 73/117] clutter/stage: Add clutter_stage_is_redraw_queued() API
- From: Ray Strode <halfline src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [mutter/wip/rstrode/rhel-8.0.0: 73/117] clutter/stage: Add clutter_stage_is_redraw_queued() API
- Date: Sun, 17 Feb 2019 17:28:58 +0000 (UTC)
commit c74dc7ce45ac21e1e7a01da20445ec7ac243e0b6
Author: Jonas Ã…dahl <jadahl gmail com>
Date: Fri Dec 21 17:28:33 2018 +0100
clutter/stage: Add clutter_stage_is_redraw_queued() API
This will be used by the screen casting code to check whether it should
wait for a frame before reading cursor state, or send only the cursor
update, if no redraw is queued.
https://gitlab.gnome.org/GNOME/mutter/merge_requests/357
clutter/clutter/clutter-stage.c | 11 +++++++++++
clutter/clutter/clutter-stage.h | 3 +++
2 files changed, 14 insertions(+)
---
diff --git a/clutter/clutter/clutter-stage.c b/clutter/clutter/clutter-stage.c
index 9352f49e8..763ec96ee 100644
--- a/clutter/clutter/clutter-stage.c
+++ b/clutter/clutter/clutter-stage.c
@@ -3722,6 +3722,17 @@ clutter_stage_ensure_redraw (ClutterStage *stage)
_clutter_master_clock_start_running (master_clock);
}
+/**
+ * clutter_stage_is_redraw_queued: (skip)
+ */
+gboolean
+clutter_stage_is_redraw_queued (ClutterStage *stage)
+{
+ ClutterStagePrivate *priv = stage->priv;
+
+ return priv->redraw_pending;
+}
+
/**
* clutter_stage_queue_redraw:
* @stage: the #ClutterStage
diff --git a/clutter/clutter/clutter-stage.h b/clutter/clutter/clutter-stage.h
index e8fbda84c..ddf08fde4 100644
--- a/clutter/clutter/clutter-stage.h
+++ b/clutter/clutter/clutter-stage.h
@@ -250,6 +250,9 @@ void clutter_stage_ensure_viewport (ClutterStage
CLUTTER_AVAILABLE_IN_ALL
void clutter_stage_ensure_redraw (ClutterStage *stage);
+CLUTTER_AVAILABLE_IN_ALL
+gboolean clutter_stage_is_redraw_queued (ClutterStage *stage);
+
#ifdef CLUTTER_ENABLE_EXPERIMENTAL_API
CLUTTER_AVAILABLE_IN_1_14
void clutter_stage_set_sync_delay (ClutterStage *stage,
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]