[totem/wip/hadess/glsink-preparation-2: 4/5] backend: Remove non-working gestures implementation
- From: Bastien Nocera <hadess src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [totem/wip/hadess/glsink-preparation-2: 4/5] backend: Remove non-working gestures implementation
- Date: Fri, 28 Jan 2022 15:56:51 +0000 (UTC)
commit 242959da4a18fa605e0ea0f6640f2df294cfed6a
Author: Bastien Nocera <hadess hadess net>
Date: Thu Jan 27 15:12:21 2022 +0100
backend: Remove non-working gestures implementation
Will be re-added as part of:
https://gitlab.gnome.org/GNOME/totem/-/issues/498
src/backend/bacon-video-widget.c | 65 ----------------------------------------
1 file changed, 65 deletions(-)
---
diff --git a/src/backend/bacon-video-widget.c b/src/backend/bacon-video-widget.c
index 0a8987a2d..6320919a3 100644
--- a/src/backend/bacon-video-widget.c
+++ b/src/backend/bacon-video-widget.c
@@ -900,58 +900,6 @@ bail:
return res;
}
-static gboolean
-bacon_video_widget_tap (ClutterTapAction *action,
- ClutterActor *actor,
- BaconVideoWidget *bvw)
-{
- ClutterInputDevice *device;
- const ClutterEvent *event;
- gboolean value;
-
- GST_DEBUG ("Tap event received");
-
- event = clutter_gesture_action_get_last_event (CLUTTER_GESTURE_ACTION (action), 0);
- if (!event)
- return CLUTTER_EVENT_PROPAGATE;
-
- device = clutter_event_get_source_device (event);
- if (device == NULL ||
- clutter_input_device_get_device_type (device) != CLUTTER_TOUCHSCREEN_DEVICE)
- return CLUTTER_EVENT_PROPAGATE;
-
- value = (clutter_actor_get_opacity (bvw->controls) == 0);
- set_controls_visibility (bvw, value, FALSE);
- return CLUTTER_EVENT_STOP;
-}
-
-static gboolean
-bacon_video_widget_swipe (ClutterSwipeAction *action,
- ClutterActor *actor,
- ClutterSwipeDirection direction,
- BaconVideoWidget *bvw)
-{
- GST_DEBUG ("Swipe event received");
-
- if ((direction & CLUTTER_SWIPE_DIRECTION_UP) ||
- (direction & CLUTTER_SWIPE_DIRECTION_DOWN)) {
- if ((direction & CLUTTER_SWIPE_DIRECTION_LEFT) ||
- (direction & CLUTTER_SWIPE_DIRECTION_RIGHT)) {
- GST_DEBUG ("Ignoring diagonal swipe 0x%X", direction);
- return CLUTTER_EVENT_PROPAGATE;
- }
- }
-
- if (direction & CLUTTER_SWIPE_DIRECTION_LEFT)
- g_signal_emit (G_OBJECT (bvw), bvw_signals[SIGNAL_SEEK_REQUESTED], 0,
- gtk_widget_get_direction (GTK_WIDGET (bvw)) == GTK_TEXT_DIR_RTL);
- if (direction & CLUTTER_SWIPE_DIRECTION_RIGHT)
- g_signal_emit (G_OBJECT (bvw), bvw_signals[SIGNAL_SEEK_REQUESTED], 0,
- gtk_widget_get_direction (GTK_WIDGET (bvw)) == GTK_TEXT_DIR_LTR);
-
- return CLUTTER_EVENT_STOP;
-}
-
static gboolean
bacon_video_widget_handle_scroll (GtkWidget *widget,
GdkEventScroll *event,
@@ -5989,7 +5937,6 @@ bacon_video_widget_initable_init (GInitable *initable,
ClutterActor *layout;
GstElement *audio_bin;
GstPad *audio_pad;
- ClutterAction *action;
GObject *item;
char *template;
@@ -6091,18 +6038,6 @@ bacon_video_widget_initable_init (GInitable *initable,
bvw->logo_frame,
bvw->frame);
- /* The video's actions */
- action = clutter_tap_action_new ();
- clutter_actor_add_action (bvw->texture, action);
- g_signal_connect (action, "tap",
- G_CALLBACK (bacon_video_widget_tap), bvw);
-
- action = clutter_swipe_action_new ();
- clutter_gesture_action_set_threshold_trigger_distance (CLUTTER_GESTURE_ACTION (action), 80.0, 80.0);
- clutter_actor_add_action (bvw->texture, action);
- g_signal_connect (action, "swipe",
- G_CALLBACK (bacon_video_widget_swipe), bvw);
-
/* The spinner */
bvw->spinner = bacon_video_spinner_actor_new ();
clutter_actor_set_name (bvw->spinner, "spinner");
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]