GtkGestureClick doesn’t send release signal and stops after a click

Hi everyone! This issue appeared at gnome discourse community first, but I couldn't get any response so considered asking it here.

Gtk4 version: 0.5.1

use gtk::prelude::*;
use gtk::{Button, Application, ApplicationWindow, GestureClick};

fn main() {
    let app = Application::builder().application_id("org.reo.testingit").build();

fn build_ui(app: &Application) {
    let b = Button::builder()
        .label("Press me")

    let gesture_click = GestureClick::new();

    gesture_click.connect_pressed(move |_gesture, _n_press, _x, _y| println!("I'm clicked"));
    gesture_click.connect_released(move |_gesture, _n_press, _x, _y| println!("I'm released"));
    gesture_click.connect_stopped(move |_a| println!("I'm gone."));

    let window = ApplicationWindow::builder()



I'm clicked
I'm gone.

As you can see, there's no release signal, the stopped signal is sent and nothing happens when you click it again. You can test this on your machine. Tested in a pure cargo project with gtk4 0.5.1 version.

Original Post in Gnome Community: GtkGestureClick doesn't send release signal and stops after a click - #2 by ramazanemreosmanoglu - Language bindings - GNOME Discourse

This topic was automatically closed 90 days after the last reply. We invite you to open a new topic if you have further questions or comments.