DomHeadroom
90ab457ebe
Rewrote string concatenation/format with f strings
2025-01-29 08:40:14 -05:00
MattHag
f5d80c30fa
solaar/ui: Remove outdated logger enabled checks
...
Logger enabled checks clutter the code unnecessarily. The checks are
now handled in a custom logger class. Eventually they can be completely
removed in the future.
Related #2664
2025-01-02 09:26:31 -05:00
MattHag
e9a58fb3e0
Introduce GTK signal types
...
Related #2273
2025-01-02 08:29:32 -05:00
MattHag
72c9dfc50c
Remove NamedInts: Convert NotificationFlag to flag
...
Related #2273
2025-01-01 10:46:04 -05:00
MattHag
571cdb5f2d
Prepare refactoring of NotificationFlag
...
Ensure behavior stays the same.
Related #2273
2025-01-01 10:46:04 -05:00
MattHag
b74e789715
Remove NamedInts: Convert Column to enum
...
Related #2273
2025-01-01 10:46:04 -05:00
MattHag
46366b2430
Fix warnings from automatic code inspections
...
Warnings found by automatic code inspection and partially tackled
- Drop distuitls inf favour of setuptools
- Replace deprecated pyudev.Device.from_device_number
- Remove unnecessary brackets
- Avoid access to private variables etc.
- Shadows built-in name
- Line length >120 characters
- Not a module level variable
- Simplify clause
and more
2024-10-11 07:42:38 -04:00
MattHag
a7ad625023
Fix about dialog
2024-10-11 07:42:38 -04:00
MattHag
a75c4b9679
ui/about: Use Model-View-Presenter pattern for testability
...
Split model and view, and enable view mocks for unit tests without GDK.
2024-10-11 07:42:38 -04:00
MattHag
67829c5807
Clean up imports ( #2537 )
...
* Remove import as _ in solaar startup
Related #2273
* Remove import as _ in listener
Related #2273
* Remove import as _ in cli init
Related #2273
* Remove import as _ in gtk
Related #2273
* Remove import as _ in show
Related #2273
* Remove import as _ in tray
Related #2273
* Remove import as _ in profiles
Related #2273
* Remove import as _ in config
Related #2273
* Remove import as _ in config panel
Related #2273
* Remove import as _ in window
Related #2273
* Remove import as _ in pair
Related #2273
* Remove import as _ in pair window
Related #2273
* Remove import as _ in cli package
Related #2273
* Remove import as _ in ui package
Related #2273
* Remove commented out code
Related #2273
* Use constant for Logitech ID
2024-07-15 08:37:18 -04:00
Matthias Hagmann
4e6361429e
refactor: Use f-strings for more exceptions and log message
...
Semi manually convert remaining strings with no translation to f-string.
2024-03-24 07:01:56 -04:00
Peter F. Patel-Schneider
50c8013cb1
ui: reduce deprecation warnings in ui
2024-03-19 09:07:21 -04:00
Matthias Hagmann
5b09ace1f5
ruff: Apply single line import format
...
# Usage
pre-commit run --all-files
Related #2295
2024-03-13 15:41:21 -04:00
Matthias Hagmann
e92f1a8a0b
Automatically upgrade strings to f-string
...
Used flynt to convert strings to f-strings, where safely possible.
Usage:
flynt .
Related #2372
2024-03-13 11:02:50 -04:00
Peter F. Patel-Schneider
1fe2eab1a4
device: move link_encrypted from status to Device
2024-03-11 08:23:27 -04:00
Peter F. Patel-Schneider
15d425c365
device: move battery information from status to Device
2024-03-11 08:23:27 -04:00
Peter F. Patel-Schneider
87285faf7f
receiver: move pairing status to new dataclass attached to receiver
2024-03-11 08:23:27 -04:00
Peter F. Patel-Schneider
135c8b8cb9
device: use status attribute for error
2024-03-09 10:36:40 -05:00
Peter F. Patel-Schneider
8154cd759f
device: use status attribute for notification_flags
2024-03-09 10:36:40 -05:00
Peter F. Patel-Schneider
6b3f09aa5d
device: use status attribute for link_encrypted
2024-03-09 10:36:40 -05:00
Peter F. Patel-Schneider
9121169f91
ui: use Battery object in GUI
2024-03-09 10:36:40 -05:00
Matthias Hagmann
7ef3059b69
clean up: Remove editor specific marks
...
Related #2273
2024-02-29 10:10:46 -05:00
Peter F. Patel-Schneider
8ae86acd65
ui: fix bug when displaying receiver notification flags
2024-02-26 10:55:14 -05:00
Matthias Hagmann
7774569971
Apply ruff format
...
Run ruff auto formatting using:
ruff format .
Related #2295
2024-02-20 15:41:10 -05:00
Peter F. Patel-Schneider
fa9494435b
device: streamline status code
2024-02-19 09:18:08 -05:00
Peter F. Patel-Schneider
12de240949
device: improve imports in logitech_receiver
...
device: move imports of ui modules to beginning of files
logitech_receiver: remove imports from __init__.py
2024-02-18 06:21:35 -05:00
Peter F. Patel-Schneider
17e6463950
ui: improve imports in ui
...
ui: move imports in about.py to top of file
ui: move imports to top of notify.py
ui: move imports to top of window.py
ui: reorder imports at beginning of __init__.py
ui: move imports to top of tray.py
ui: move common code out of __init__.py to common.py
ui: move imports to top of __init___.py
2024-02-18 06:21:35 -05:00
Peter F. Patel-Schneider
e6aacc42dd
ui: tidy up scrolling appearance in configuration panel
2024-02-11 16:50:31 -05:00
MattHag
87658fb189
logging: Simplify logger instantiation
...
* logging: Simplify logger instantiation
Relates #2254
* logging: Remove aliases
Relates #2254
* logging: Replace deprecated warn with warning
Related #2254
* logging: Fix mistake
Related #2257
2024-02-10 13:55:27 -05:00
Peter F. Patel-Schneider
db4e40e3ac
device: add extended report rate setting
2024-02-01 10:13:03 -05:00
Peter F. Patel-Schneider
5ca1790cb8
ui: better handling and installation of icons
2023-11-19 12:06:04 -05:00
Peter F. Patel-Schneider
b50b88be06
ui: update codename when device status changes
2023-10-06 16:17:47 -04:00
Peter F. Patel-Schneider
04f2adfd75
ui: remove deprecated GTK code
2023-03-08 20:40:27 -05:00
Peter F. Patel-Schneider
57c0c5d4b3
ui: don't show wireless link or battery information when unknown or not present
2023-02-16 07:39:36 -05:00
Peter F. Patel-Schneider
dcbf547195
ui: online devices with no battery information probably don't have a battery
2023-02-16 07:39:36 -05:00
Peter F. Patel-Schneider
ef0db31687
ui: improve determination of whether pairing possible
2023-01-09 05:20:16 -05:00
Matt Broadway
f8a6396cdf
ui: Filter and escape technical detail fields ( #1953 )
...
Since the values for the 'technical details' fields are arbitrary
some characters need to be filtered out for them to display properly.
markup characters such as < or > are now escaped and null characters
are removed.
Empty fields are no longer displayed in technical details.
2023-01-02 15:07:26 -05:00
Peter F. Patel-Schneider
d6847a6ce4
ui: only update remaining pairings after sucessful pairing
2022-10-21 16:48:07 -04:00
Peter F. Patel-Schneider
a6669da179
ui: change security tooltip for unencrypted wireless connections
2022-09-01 10:21:45 -04:00
Peter F. Patel-Schneider
adf5a07919
ui: better presentation of battery information
2022-07-10 11:08:28 -04:00
Vinícius
6022c37325
ui: add device selector to Set rule editor
2022-01-24 11:12:04 -05:00
Peter F. Patel-Schneider
8a87b9b013
rules: add Solaar rules command to set settings
...
testing
2022-01-13 18:23:12 -05:00
Christian Tacke
d9dbf53868
Keep left Tree at Minimal Size
...
When resizing the window or switching entries in the left
tree, the width of the tree changes and takes more space
than required.
Switch it over to only take the minimal amount of space and
do not extend when resizing the window.
2021-12-25 12:19:29 -05:00
Peter F. Patel-Schneider
174d0388ca
ui: display percentage estimates from battery voltage
2021-12-20 11:30:29 -05:00
Peter F. Patel-Schneider
4c9d9e17d6
gui: fix bug when adding new receiver to tray menu
2021-11-22 11:32:25 -05:00
Hugo Osvaldo Barrera
22bf4fafff
Drop unnecessary __future__ imports
...
These are all active by default on all recent Python versions.
2021-10-30 16:49:41 -04:00
Hugo Osvaldo Barrera
b96d16672b
Drop obsolete encoding declaration
...
This was only parsed in Python 2.
Python 3 only supports UTF-8 for source files, and that's what it uses.
2021-10-30 16:49:41 -04:00
Jocelyn Thode
138fe4c756
ui: fix device not always castable as bool
2021-10-28 12:49:20 -04:00
Peter F. Patel-Schneider
453be19356
ui: make about and quit buttons more translatable
2021-10-01 12:35:33 -04:00
Peter F. Patel-Schneider
30f56a1c0f
device: use 0xFF instead of 0 for direct-connected devices
2021-08-22 11:16:41 -04:00