diff options
author | Michael Bohlender <michael.bohlender@kdemail.net> | 2018-04-19 11:34:24 +0200 |
---|---|---|
committer | Michael Bohlender <michael.bohlender@kdemail.net> | 2018-04-19 11:36:49 +0200 |
commit | 49b240ffa141dbab6f7d03c4d682abcd70faf594 (patch) | |
tree | 03edb765ac163b2a477f83a4fa505217919eeeda /views | |
parent | 5811835d67f215258c28e14f65059e7b22a3d3f5 (diff) | |
download | kube-49b240ffa141dbab6f7d03c4d682abcd70faf594.tar.gz kube-49b240ffa141dbab6f7d03c4d682abcd70faf594.zip |
hide time chooser when daylong event
Diffstat (limited to 'views')
-rw-r--r-- | views/calendar/qml/DayChooser.qml | 7 | ||||
-rw-r--r-- | views/calendar/qml/EventView.qml | 31 |
2 files changed, 28 insertions, 10 deletions
diff --git a/views/calendar/qml/DayChooser.qml b/views/calendar/qml/DayChooser.qml index a18bafd0..0a40b1a9 100644 --- a/views/calendar/qml/DayChooser.qml +++ b/views/calendar/qml/DayChooser.qml | |||
@@ -97,7 +97,6 @@ Item { | |||
97 | 97 | ||
98 | Layout.column: 1 | 98 | Layout.column: 1 |
99 | Layout.fillWidth: true | 99 | Layout.fillWidth: true |
100 | |||
101 | } | 100 | } |
102 | 101 | ||
103 | WeekNumberColumn { | 102 | WeekNumberColumn { |
@@ -116,6 +115,12 @@ Item { | |||
116 | 115 | ||
117 | Layout.fillWidth: true | 116 | Layout.fillWidth: true |
118 | Layout.fillHeight: true | 117 | Layout.fillHeight: true |
118 | |||
119 | delegate: Kube.AbstractButton { | ||
120 | text: model.day | ||
121 | |||
122 | width: Kube.Units.gridUnit * 3 | ||
123 | } | ||
119 | } | 124 | } |
120 | } | 125 | } |
121 | } | 126 | } |
diff --git a/views/calendar/qml/EventView.qml b/views/calendar/qml/EventView.qml index 6f34cefa..c86f0f42 100644 --- a/views/calendar/qml/EventView.qml +++ b/views/calendar/qml/EventView.qml | |||
@@ -26,6 +26,8 @@ import org.kube.framework 1.0 as Kube | |||
26 | FocusScope { | 26 | FocusScope { |
27 | id: root | 27 | id: root |
28 | 28 | ||
29 | property bool daylong | ||
30 | |||
29 | Rectangle { | 31 | Rectangle { |
30 | anchors { | 32 | anchors { |
31 | top: parent.top | 33 | top: parent.top |
@@ -49,14 +51,16 @@ FocusScope { | |||
49 | 51 | ||
50 | Kube.TextField { | 52 | Kube.TextField { |
51 | width: parent.width | 53 | width: parent.width |
52 | placeholderText: "Titel" | 54 | placeholderText: "Title" |
53 | } | 55 | } |
54 | RowLayout { | 56 | RowLayout { |
55 | spacing: Kube.Units.smallSpacing | 57 | spacing: Kube.Units.smallSpacing |
56 | 58 | ||
57 | DayChooser { } | 59 | DayChooser { } |
58 | 60 | ||
59 | TimeChooser { } | 61 | TimeChooser { |
62 | visible: !root.daylong | ||
63 | } | ||
60 | 64 | ||
61 | Kube.Label { | 65 | Kube.Label { |
62 | text: " " + qsTr("till") + " " | 66 | text: " " + qsTr("till") + " " |
@@ -64,7 +68,10 @@ FocusScope { | |||
64 | 68 | ||
65 | DayChooser { } | 69 | DayChooser { } |
66 | 70 | ||
67 | TimeChooser { } | 71 | TimeChooser { |
72 | visible: !root.daylong | ||
73 | |||
74 | } | ||
68 | } | 75 | } |
69 | 76 | ||
70 | RowLayout { | 77 | RowLayout { |
@@ -72,16 +79,22 @@ FocusScope { | |||
72 | 79 | ||
73 | RowLayout { | 80 | RowLayout { |
74 | Layout.fillHeight: true | 81 | Layout.fillHeight: true |
75 | Kube.CheckBox { | 82 | Kube.CheckBox { |
76 | } | 83 | checked: root.daylong |
77 | 84 | ||
78 | Kube.Label { | 85 | onClicked: { |
79 | text: "daylong" | 86 | root.daylong = !root.daylong |
80 | } | 87 | } |
88 | } | ||
89 | |||
90 | Kube.Label { | ||
91 | text: "daylong" | ||
92 | } | ||
81 | } | 93 | } |
82 | 94 | ||
83 | Kube.ComboBox { | 95 | Kube.ComboBox { |
84 | model: ["once", "reoccuring"] | 96 | model: ["once", "dayly", "weekly"] |
97 | |||
85 | } | 98 | } |
86 | } | 99 | } |
87 | 100 | ||