mirror of
https://github.com/morgan9e/dash-to-panel
synced 2026-04-15 00:34:05 +09:00
enable prefs dialog search, fix sensitive flag of opacity and gradiant rows
This commit is contained in:
17
prefs.js
17
prefs.js
@@ -166,6 +166,9 @@ const Preferences = class {
|
||||
this._builder.set_translation_domain(Me.metadata['gettext-domain']);
|
||||
|
||||
if (window) {
|
||||
this._window = window;
|
||||
window.set_search_enabled(true);
|
||||
|
||||
// dialogs
|
||||
this._builder.add_from_file(Me.path + '/ui/AnimateAppIconHoverOptions.ui');
|
||||
this._builder.add_from_file(Me.path + '/ui/BoxDotOptions.ui');
|
||||
@@ -1026,6 +1029,13 @@ const Preferences = class {
|
||||
'sensitive',
|
||||
Gio.SettingsBindFlags.DEFAULT);
|
||||
|
||||
if (this._window) {
|
||||
this._settings.bind('trans-use-custom-opacity',
|
||||
this._builder.get_object('trans_opacity_box2'),
|
||||
'sensitive',
|
||||
Gio.SettingsBindFlags.DEFAULT);
|
||||
}
|
||||
|
||||
this._builder.get_object('trans_opacity_override_switch').connect('notify::active', (widget) => {
|
||||
if (!widget.get_active())
|
||||
this._builder.get_object('trans_dyn_switch').set_active(false);
|
||||
@@ -1061,6 +1071,13 @@ const Preferences = class {
|
||||
'sensitive',
|
||||
Gio.SettingsBindFlags.DEFAULT);
|
||||
|
||||
if (this._window) {
|
||||
this._settings.bind('trans-use-custom-gradient',
|
||||
this._builder.get_object('trans_gradient_box2'),
|
||||
'sensitive',
|
||||
Gio.SettingsBindFlags.DEFAULT);
|
||||
}
|
||||
|
||||
rgba.parse(this._settings.get_string('trans-gradient-top-color'));
|
||||
this._builder.get_object('trans_gradient_color1_colorbutton').set_rgba(rgba);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user