GTK FlowBox/ListBox and Touchscreen

Hello,

I just discovered that Lollypop touch support is broken on ArchLinux and Fedora 30 (even on Xorg)

Here a small example, what am I doing wrong? Is this a bug?

In this code, as soon you want to scroll the view, child-activated signal is emitted :-/

import gi
gi.require_version("Gtk", "3.0")
from gi.repository import GLib, Gtk, Gdk, GObject, GdkPixbuf


class MyDemoApp():

    def __init__(self):
        window = Gtk.Window()
        window.set_title("My demo window")
        window.set_default_size(800, 800)
        window.set_position(Gtk.WindowPosition.CENTER)
        window.connect('destroy', self.destroy)
        scrolled = Gtk.ScrolledWindow()
        scrolled.set_property("expand", True)
        self.listbox = Gtk.ListBox()
        self.listbox.set_hexpand(True)
        self.listbox.set_property("valign", Gtk.Align.START)
        self.listbox.connect("row-activated", lambda x, y: x.hide())
        scrolled.add(self.listbox)
        window.add(scrolled)
        window.show_all()
        
    def load(self, count):
        for i in range(0, count):
            image = Gtk.Image.new_from_icon_name("org.gnome.Nautilus", Gtk.IconSize.INVALID)
            image.set_pixel_size(200)
            image.show()
            self.listbox.add(image)

    def destroy(self, window):
        Gtk.main_quit()

def main():
    app = MyDemoApp()
    app.load(200)
    Gtk.main()


if __name__ == '__main__':
    main()

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.