Skip to content
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

Listbox for plugindialog #2137

Merged
merged 1 commit into from
Nov 15, 2023
Merged

Conversation

infirit
Copy link
Contributor

@infirit infirit commented Sep 10, 2023

I still see some weirdness with enabling/disabling plugins but I suspect I messed up my gsettings in the process. Putting it out here as a possible option to use for blueman-manager's device list.

The idea here is that we make our own widget in the factory function and then optionally bind the GObject property to widgets. Then updating the GObject property will automatically update the UI. The plugin dialog is not very dynamic and used stateful SimpleAction for the checkbox but binding the enabled property is also an option.

mypy was very unhappy so some of the typing annotation looks weird and I had to cast the PluginItem properties to convince it.

The other option is to use ListBoxRows and insert them manually into the ListBox.

@infirit infirit force-pushed the plugindialoglistbox branch 3 times, most recently from 154c0c3 to cd34291 Compare October 20, 2023 21:43
@infirit infirit changed the title WIP Listbox for plugindialog Listbox for plugindialog Oct 20, 2023
@infirit
Copy link
Contributor Author

infirit commented Oct 20, 2023

The weirdness was because I messed up gsettings. Cleaned it up and it's ready for review.

Hopefully based of this I can do the same for the ManagerDeviceList to make it much easier to implement a new design.

@infirit infirit marked this pull request as ready for review October 20, 2023 21:47
@infirit infirit requested a review from cschramm October 20, 2023 21:48
@infirit infirit force-pushed the plugindialoglistbox branch from cd34291 to d3a18b3 Compare October 20, 2023 22:15
@blueman-project blueman-project deleted a comment from sonarqubecloud bot Oct 20, 2023
@infirit infirit force-pushed the plugindialoglistbox branch from d3a18b3 to 3ffbbd2 Compare October 20, 2023 22:27
cschramm
cschramm previously approved these changes Oct 29, 2023
Copy link
Member

@cschramm cschramm left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Didn't test but the code lgtm.

blueman/gui/applet/PluginDialog.py Outdated Show resolved Hide resolved
blueman/gui/applet/PluginDialog.py Show resolved Hide resolved
@cschramm cschramm added this to the 2.4 milestone Oct 29, 2023
@infirit infirit force-pushed the plugindialoglistbox branch from 3ffbbd2 to bfa4bd5 Compare November 12, 2023 12:25
@infirit infirit requested a review from cschramm November 12, 2023 12:26
@infirit infirit enabled auto-merge (rebase) November 12, 2023 15:05
cschramm
cschramm previously approved these changes Nov 12, 2023
blueman/gui/applet/PluginDialog.py Outdated Show resolved Hide resolved
Copy link

Kudos, SonarCloud Quality Gate passed!    Quality Gate passed

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 0 Code Smells

No Coverage information No Coverage information
0.0% 0.0% Duplication

@infirit infirit requested a review from cschramm November 15, 2023 20:34
@infirit infirit merged commit 8f64174 into blueman-project:main Nov 15, 2023
21 of 22 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants