summaryrefslogtreecommitdiff
path: root/Tags.qml
diff options
context:
space:
mode:
authorTimotej Lazar <timotej.lazar@araneo.si>2021-09-07 19:25:32 +0200
committerTimotej Lazar <timotej.lazar@araneo.si>2021-09-16 20:33:44 +0200
commitff63d29adbbc4fb291dbcbdc14cc8c6701f2998a (patch)
tree46c37a91b94aba8f7ff602e19e899e2dd2413040 /Tags.qml
parent54bb1c1c2be5fdd1b8e1eda7c9cd6fe40337800f (diff)
Redecorate sidebar
Use a single dialog for loading event and tag files. Inline Tags. Also do various other things.
Diffstat (limited to 'Tags.qml')
-rw-r--r--Tags.qml37
1 files changed, 0 insertions, 37 deletions
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
- }
- }
- }
- }
-}