1
0
Fork 0
mirror of https://github.com/Zedfrigg/ironbar.git synced 2025-04-20 11:54:23 +02:00
Commit graph

25 commits

Author SHA1 Message Date
c702f6fffa
refactor: major client code changes
This does away with `lazy_static` singletons for all the clients, instead putting them all inside a `Clients` struct on the `Ironbar` struct.

Client code has been refactored in places to accommodate this, and module code has been updated to get the clients the new way.

The Wayland client has been re-written from the ground up to remove a lot of the needless complications, provide a nicer interface and reduce some duplicate data.

The MPD music client has been overhauled to use the `mpd_utils` crate, which simplifies the code within Ironbar and should offer more robustness and better recovery when connection is lost to the server.

The launcher module in particular has been affected by the refactor.
2024-01-09 23:33:07 +00:00
57b57ed002
refactor: pass context into modules controllers
This paves the way to keep things tidier for the next refactors.
2024-01-07 23:42:34 +00:00
b4d75450ac
fix(regression): GTK refactor causing updates to be missed
Regression introduced by recent GTK refactor.

The `glib_recv` macros  previously using the passed in expression as the receiver, which was causing a new receiver to be created *every* time an event was received. This caused some peculiar behaviours where some events just never got through if sent too close to each other.

This was most obvious in the `workspaces` module.

Fixes #381
2023-12-31 15:56:41 +00:00
e847a84c21
refactor: fix casting based clippy warnings 2023-12-18 22:09:21 +00:00
bea442ed96
refactor: update gtk/glib, remove glib channels
This is a major refactor which updates GTK, GLib and GTK Layer Shell to their latest versions.

GLib channels, previously used for receiving events on the GLib Main Context thread have been deprecated and a new method for running Futures on the main thread has been added instead. This commit also replaces all the deprecated code with this.

As part of the above, a bug was uncovered related to creating the GLib main context inside the Tokio runtime. Spawning of Tokio tasks has been refactored to fix this.
2023-12-18 22:09:21 +00:00
fea1f18524
refactor: fix new clippy warnings, fmt 2023-08-25 22:55:12 +01:00
89ec06fc7b
fix(music): hide album art widget when no image 2023-07-26 22:03:27 +01:00
2367faab04
fix(image): using fallback in places it shouldn't 2023-07-26 21:49:45 +01:00
b7ee794bfc
feat(ipc): commands for opening/closing popups
Also includes some refactoring around related GTK helper code
2023-07-16 19:15:55 +01:00
1759945912
fix(music): correctly show/hide popup elements based on player capabilities 2023-06-30 19:27:00 +01:00
12053f111a
feat(music): progress/seek bar in popup
Resolves #128.
2023-06-30 19:26:49 +01:00
e11177fea3
fix: add sensible class names for icon labels
BREAKING CHANGE: Where both textual and image icons are supported, CSS classes have changed to better reflect their targets. `.icon` has changed to `.icon-box` and `.icon` now targets the underlying element. `.label` has been changed to `.icon.text-icon`. This affects icons on the **music**, **workspaces**, and **clipboard** modules.

Resolves #185.
2023-06-12 22:25:23 +01:00
22b630a10b fix: broken nerd font icons
Fixes #152.
2023-05-21 14:04:18 +01:00
87ca399220 fix: poor error handling for missing images
Previously images that could not be located were handled by throwing a
full report error, which incorrectly stated it was an invalid image
*type*.

This changes the image handling to instead log a single-line warning
directly in the image provider code, reducing the error handling
required by each consumer.

Resolves #146.
2023-05-20 14:38:39 +01:00
dea66415c2
feat: module-level name and class options
BREAKING CHANGE: To allow for the `name` property, any widgets that were previously targeted by name should be targeted by class instead. This affects **all modules and all popups**, as well as several widgets inside modules. **This will break a lot of rules in your stylesheet**. To attempt to mitigate the damage, a migration script can be found [here](https://raw.githubusercontent.com/JakeStanger/ironbar/master/scripts/migrate-styles.sh) that should get you most of the way.

Resolves #75.
2023-05-06 13:22:35 +01:00
2a155b9aa8
feat(music): add css selector for button contents 2023-05-02 23:08:13 +01:00
76e2b7ba3e
feat(music): option to hide status icon on widget
Adds new `show_status_icon` option.

Resolves #97.
2023-04-23 13:00:37 +01:00
2da28b9bf5
feat: ability to configure image icon sizes
Adds `icon_size` option to following widgets:

- `clipboard`
- `launcher`
- `music`
- `workspaces`

Also adds `cover_image_size` option to `music`.
2023-04-22 22:22:49 +01:00
dfe1964abf
feat(custom): slider widget
Resolves partially #68.
2023-04-10 00:17:09 +01:00
96141d4990
feat(music): support for using images in name_map, additional icon options 2023-01-30 11:51:01 +00:00
3cf9be89fd
feat: global icon theme setting
BREAKING CHANGE: This removes the `icon_theme` option from `launcher` and `focused`. You will need to set this at the top of your config instead.
2023-01-30 11:51:01 +00:00
393800aaa2
feat(custom): image widget 2023-01-30 11:51:01 +00:00
5772711192
fix(music): remote mpris album art not showing
Fixes #55.
2023-01-30 11:47:56 +00:00
07dbf78010
feat(focused): ability to truncate label text 2023-01-28 23:01:44 +00:00
97502559b3
refactor(music): split config code into separate file 2023-01-28 22:43:22 +00:00