From bec46fc2fcb8d0ec02b56472b4bf9f21139e5f45 Mon Sep 17 00:00:00 2001 From: Mitchell Hashimoto Date: Thu, 2 Jan 2025 19:17:34 -0800 Subject: [PATCH] Revert "gtk: equalize on double clicking the split handle (#3557)" This reverts commit 09470ede55c26e042a3c9805a8175e972b7cc89b, reversing changes made to 6139cb00cf6a50df2d47989dfb91b97286dd7879. --- src/apprt/gtk/Split.zig | 23 ----------------------- 1 file changed, 23 deletions(-) diff --git a/src/apprt/gtk/Split.zig b/src/apprt/gtk/Split.zig index 7ac78df00..2d428acb2 100644 --- a/src/apprt/gtk/Split.zig +++ b/src/apprt/gtk/Split.zig @@ -111,16 +111,6 @@ pub fn init( // Keep a long-lived reference, which we unref in destroy. _ = c.g_object_ref(paned); - // Clicks - const gesture_click = c.gtk_gesture_click_new(); - errdefer c.g_object_unref(gesture_click); - c.gtk_event_controller_set_propagation_phase(@ptrCast(gesture_click), c.GTK_PHASE_CAPTURE); - c.gtk_gesture_single_set_button(@ptrCast(gesture_click), 1); - c.gtk_widget_add_controller(paned, @ptrCast(gesture_click)); - - // Signals - _ = c.g_signal_connect_data(gesture_click, "pressed", c.G_CALLBACK(>kMouseDown), self, null, c.G_CONNECT_DEFAULT); - // Update all of our containers to point to the right place. // The split has to point to where the sibling pointed to because // we're inheriting its parent. The sibling points to its location @@ -246,19 +236,6 @@ pub fn equalize(self: *Split) f64 { return weight; } -fn gtkMouseDown( - _: *c.GtkGestureClick, - n_press: c.gint, - _: c.gdouble, - _: c.gdouble, - ud: ?*anyopaque, -) callconv(.C) void { - if (n_press == 2) { - const self: *Split = @ptrCast(@alignCast(ud)); - _ = equalize(self); - } -} - // maxPosition returns the maximum position of the GtkPaned, which is the // "max-position" attribute. fn maxPosition(self: *Split) f64 {