Gradience icon indicating copy to clipboard operation
Gradience copied to clipboard

Prevent set_gtk3_theme from crashing

Open lavafroth opened this issue 1 year ago • 0 comments

Description

When using GSettingsSetting outside a flatpak environment, the added getter, setter and reset methods should prevent the AttributeError when attempting to set the GTK3 theme.

Note: I used python-black for formatting the code and it made a lot of weird opinionated changes.

Fixes #811

Type of change

  • [x] Bugfix (Change which fixes an issue)
  • [ ] New feature (Change which adds new functionality)
  • [ ] Enhancement (Change which slightly improves existing code)
  • [ ] Breaking change (This change will introduce incompatibility with existing functionality)

Changelog

  • Adds a function to stage the gsettings command to be executed.
  • Adds the equivalent setter, getter and reset functions for GSettingsSetting.

Testing

  • [x] I have tested my changes and verified that they work as expected

How to test the changes

Run ./local.sh in a non-flatpak environment, apply a theme, making sure to check the GTK3 checkbox. The program should ask you to log out to see the effects.

lavafroth avatar Aug 20 '23 12:08 lavafroth