-
-
Notifications
You must be signed in to change notification settings - Fork 207
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Rewrite the SendTo dialog to use a Gtk.Listbox #2552
base: main
Are you sure you want to change the base?
Conversation
I did not review this in detail, but it makes a lot of sense to me 👌 |
b669ef1
to
a09945d
Compare
Decided to remove the trusted and paired icons from the list as afaics they really serve no purpose when sending files over bluetooth. I added a new icon to indicate if the device advertises obex object push. Also added a togglebutton but not sure if this is useful (not happy with how it looks regardless). |
bf3d614
to
d483437
Compare
This drops the refcount and python destroys the DBusObjectManager
6db6849
to
668042e
Compare
|
I'm mostly done with it and will undraft it soon. Here is a quick recording of the list. |
668042e
to
66a7348
Compare
66a7348
to
1e26be1
Compare
|
I'm happy with this now. So ready for review and testing :-) |
Rewrite the sendto device list to use the much simpler and flexible Gtk.ListBox.
The list has only one job now which is present a list of devices to the user. It doesn't manage any state for devices or adapters.
The list now also contains devices from all Adapters and filters based on the selection in the combobox. No more rebuilding the whole list when a different adapter is selected.
In the process I also changed the following:
Old description
This is a rough, mostly working, proof of concept to replace the TreeView in blueman-sendto we currently have with a much simpler and flexible Gtk.ListBox. Before I go further I'd like some feedback on the overall design of it. I do want to move the bluez.Manager and bluez.AnyDevice signal handling further up into apps/blueman-sendto as we already have them there anyway.I do want to make the Gtk.ListBox and Gtk.ListBoxRow only be responsible for presenting the data. Not have it handle state on adapters/devices internally, this will be done through methods. Using properties for the row in blueman-manager may not be ideal so maybe I should use some sort of properties_update method and pass in all the changes in one go.
I like to treat this as a blueprint for when I start working on the Gtk.ListBox for blueman-manager so we can finally implement some of the designs done by users some time ago.
ps: I'm sure mypy will be unhappy with me but it's just a proof of concept for now.