[clutter] interactive/transitions: Jump to middle-click coordinates
- From: Emmanuele Bassi <ebassi src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [clutter] interactive/transitions: Jump to middle-click coordinates
- Date: Wed, 28 Mar 2012 11:47:32 +0000 (UTC)
commit 2355b57aabd984013b4ec5ec76b192ff8065ef65
Author: Emmanuele Bassi <ebassi linux intel com>
Date: Wed Mar 28 12:46:30 2012 +0100
interactive/transitions: Jump to middle-click coordinates
Middle click will update an existing transition while in flight, and
skip it.
tests/interactive/test-transitions.c | 6 +++++-
1 files changed, 5 insertions(+), 1 deletions(-)
---
diff --git a/tests/interactive/test-transitions.c b/tests/interactive/test-transitions.c
index 4606913..47b8ba2 100644
--- a/tests/interactive/test-transitions.c
+++ b/tests/interactive/test-transitions.c
@@ -75,6 +75,10 @@ on_button_press (ClutterActor *actor,
clutter_text_set_text (CLUTTER_TEXT (easing_mode_label), text);
g_free (text);
}
+ else if (event->button == CLUTTER_BUTTON_MIDDLE)
+ {
+ clutter_actor_set_position (rectangle, event->x, event->y);
+ }
else if (event->button == CLUTTER_BUTTON_PRIMARY)
{
ClutterAnimationMode cur_mode;
@@ -92,7 +96,7 @@ on_button_press (ClutterActor *actor,
clutter_actor_restore_easing_state (rectangle);
}
- return TRUE;
+ return CLUTTER_EVENT_STOP;
}
static gboolean
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]