Commands Page: Use AdwEntryRow

This commit is contained in:
Romain Vigier
2024-03-04 15:17:43 +00:00
parent e3c6d67fe9
commit 7bff19f830
6 changed files with 6 additions and 46 deletions
-20
View File
@@ -1,20 +0,0 @@
// SPDX-FileCopyrightText: Night Theme Switcher Contributors
// SPDX-License-Identifier: GPL-3.0-or-later
import GObject from 'gi://GObject';
import Gtk from 'gi://Gtk';
export class ClearableEntry extends Gtk.Entry {
static {
GObject.registerClass({
GTypeName: 'ClearableEntry',
Template: 'resource:///org/gnome/Shell/Extensions/nightthemeswitcher/preferences/ui/ClearableEntry.ui',
}, this);
}
onIconReleased(entry, position) {
if (position === Gtk.EntryIconPosition.SECONDARY)
entry.text = '';
}
}