From ff63d29adbbc4fb291dbcbdc14cc8c6701f2998a Mon Sep 17 00:00:00 2001 From: Timotej Lazar Date: Tue, 7 Sep 2021 19:25:32 +0200 Subject: Redecorate sidebar Use a single dialog for loading event and tag files. Inline Tags. Also do various other things. --- Tags.qml | 37 ------------------------------------- 1 file changed, 37 deletions(-) delete mode 100644 Tags.qml (limited to 'Tags.qml') diff --git a/Tags.qml b/Tags.qml deleted file mode 100644 index 9e64cff..0000000 --- a/Tags.qml +++ /dev/null @@ -1,37 +0,0 @@ -// SPDX-License-Identifier: Unlicense - -import QtQuick 2.12 -import QtQuick.Controls 2.13 - -import 'util.js' as Util - -// Tag list. -Flow { - id: control - - property alias model: buttons.model - - signal clicked(string tag) - - // Try passing key to each field input in order. - Keys.enabled: enabled - Keys.forwardTo: Array.from({ length: buttons.count }, (_, i) => buttons.itemAt(i)) - - spacing: 5 - - Repeater { - id: buttons - delegate: Button { - text: Util.addShortcut(modelData.tag, modelData.key) - focusPolicy: Qt.NoFocus - implicitWidth: implicitContentWidth + 2*padding - onClicked: control.clicked(modelData.tag) - Keys.onPressed: { - if (event.text === modelData.key) { - clicked() - event.accepted = true - } - } - } - } -} -- cgit v1.3