2022-08-19 12:23:25 +00:00
|
|
|
using Gtk 4.0;
|
|
|
|
using Adw 1;
|
|
|
|
|
2023-08-15 21:57:56 +00:00
|
|
|
template $GradiencePluginRow : Adw.ActionRow {
|
2023-06-26 18:52:04 +00:00
|
|
|
activatable-widget: switch;
|
|
|
|
|
2022-11-20 21:02:10 +00:00
|
|
|
[suffix]
|
|
|
|
Switch switch {
|
|
|
|
valign: center;
|
|
|
|
tooltip-text: _("Toggle Plugin");
|
2023-08-15 21:57:56 +00:00
|
|
|
state-set => $on_switch_toggled();
|
2022-11-20 21:02:10 +00:00
|
|
|
}
|
|
|
|
|
2024-01-04 00:33:59 +00:00
|
|
|
// TODO: Detect if plugin has preferences, and if it does display the
|
|
|
|
// settings button
|
2022-11-11 21:04:46 +00:00
|
|
|
|
2024-01-04 00:33:59 +00:00
|
|
|
// [suffix]
|
|
|
|
// Button settings-button {
|
|
|
|
// valign: center;
|
|
|
|
// icon-name: "settings-symbolic";
|
|
|
|
// tooltip-text: _("Preferences");
|
|
|
|
// clicked => $on_settings_plugin_clicked();
|
|
|
|
|
|
|
|
// styles [
|
|
|
|
// "flat",
|
|
|
|
// ]
|
|
|
|
// }
|
2022-11-11 21:04:46 +00:00
|
|
|
|
2022-08-19 18:33:36 +00:00
|
|
|
[suffix]
|
|
|
|
Button remove-button {
|
|
|
|
valign: center;
|
2022-09-25 12:17:04 +00:00
|
|
|
icon-name: "user-trash-symbolic";
|
2022-09-29 18:06:42 +00:00
|
|
|
tooltip-text: _("Remove Plugin");
|
2023-08-15 21:57:56 +00:00
|
|
|
clicked => $on_remove_plugin_clicked();
|
2022-08-19 18:33:36 +00:00
|
|
|
}
|
2022-09-14 14:55:35 +00:00
|
|
|
}
|