[nautilus/wip/antoniof/flow-box-preparation: 30/46] view-icon-controller: Don’t use event in long press callback
- From: António Fernandes <antoniof src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [nautilus/wip/antoniof/flow-box-preparation: 30/46] view-icon-controller: Don’t use event in long press callback
- Date: Wed, 22 Dec 2021 00:36:38 +0000 (UTC)
commit 6c194033a66b9e85c5fd8fb5ff5a830154662efd
Author: Ernestas Kulik <ernestask gnome org>
Date: Fri Jul 13 13:35:32 2018 +0300
view-icon-controller: Don’t use event in long press callback
The coordinates in parameters are perfectly fine.
src/nautilus-view-icon-controller.c | 5 +----
1 file changed, 1 insertion(+), 4 deletions(-)
---
diff --git a/src/nautilus-view-icon-controller.c b/src/nautilus-view-icon-controller.c
index ed4bee7df..569cbed51 100644
--- a/src/nautilus-view-icon-controller.c
+++ b/src/nautilus-view-icon-controller.c
@@ -754,7 +754,6 @@ on_longpress_gesture_pressed_callback (GtkGestureLongPress *gesture,
NautilusViewIconController *self;
g_autoptr (GList) selection = NULL;
GtkFlowBoxChild *child_at_pos;
- GdkEventButton *event_button;
GdkEventSequence *event_sequence;
GdkEvent *event;
@@ -762,12 +761,10 @@ on_longpress_gesture_pressed_callback (GtkGestureLongPress *gesture,
event = (GdkEvent *) gtk_gesture_get_last_event (GTK_GESTURE (gesture), event_sequence);
self = NAUTILUS_VIEW_ICON_CONTROLLER (user_data);
- event_button = (GdkEventButton *) event;
/* Need to update the selection so the popup has the right actions enabled */
selection = nautilus_view_get_selection (NAUTILUS_VIEW (self));
- child_at_pos = gtk_flow_box_get_child_at_pos (self->view_ui,
- event_button->x, event_button->y);
+ child_at_pos = gtk_flow_box_get_child_at_pos (self->view_ui, x, y);
if (child_at_pos != NULL)
{
NautilusFile *selected_file;
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]