Changeset View
Changeset View
Standalone View
Standalone View
src/qtquick/qml/Page.qml
Show First 20 Lines • Show All 81 Lines • ▼ Show 20 Line(s) | 81 | enum ViewMode { | |||
---|---|---|---|---|---|
82 | Tiles, | 82 | Tiles, | ||
83 | Icons, | 83 | Icons, | ||
84 | Preview | 84 | Preview | ||
85 | } | 85 | } | ||
86 | 86 | | |||
87 | title: newStuffEngine.name | 87 | title: newStuffEngine.name | ||
88 | NewStuff.Engine { | 88 | NewStuff.Engine { | ||
89 | id: newStuffEngine; | 89 | id: newStuffEngine; | ||
90 | onMessage: root.message(message); | 90 | property string statusMessage; | ||
91 | onIdleMessage: root.idleMessage(message); | 91 | onMessage: { | ||
92 | onBusyMessage: root.busyMessage(message); | 92 | root.message(message); | ||
93 | onErrorMessage: root.errorMessage(message); | 93 | statusMessage = message; | ||
94 | } | ||||
95 | onIdleMessage: { | ||||
96 | root.idleMessage(message); | ||||
97 | statusMessage = message; | ||||
98 | } | ||||
99 | onBusyMessage: { | ||||
100 | root.busyMessage(message); | ||||
101 | statusMessage = message; | ||||
102 | } | ||||
103 | onErrorMessage: { | ||||
104 | root.errorMessage(message); | ||||
105 | statusMessage = message; | ||||
106 | } | ||||
94 | } | 107 | } | ||
95 | NewStuff.QuestionAsker {} | 108 | NewStuff.QuestionAsker {} | ||
96 | 109 | | |||
97 | titleDelegate: QtLayouts.RowLayout { | 110 | titleDelegate: QtLayouts.RowLayout { | ||
98 | QtLayouts.Layout.fillWidth: true | 111 | QtLayouts.Layout.fillWidth: true | ||
99 | Kirigami.Heading { | 112 | Kirigami.Heading { | ||
100 | id: title | 113 | id: title | ||
101 | level: 1 | 114 | level: 1 | ||
▲ Show 20 Lines • Show All 122 Lines • ▼ Show 20 Line(s) | 235 | EntryGridDelegates.ThumbDelegate { | |||
224 | uninstallLabel: root.uninstallLabel | 237 | uninstallLabel: root.uninstallLabel | ||
225 | } | 238 | } | ||
226 | } | 239 | } | ||
227 | 240 | | |||
228 | Component { | 241 | Component { | ||
229 | id: detailsPage; | 242 | id: detailsPage; | ||
230 | NewStuff.EntryDetails { } | 243 | NewStuff.EntryDetails { } | ||
231 | } | 244 | } | ||
245 | | ||||
246 | Item { | ||||
247 | anchors.fill: parent | ||||
248 | opacity: newStuffEngine.isLoading ? 1 : 0 | ||||
249 | Behavior on opacity { NumberAnimation { duration: Kirigami.Units.longDuration; } } | ||||
250 | visible: opacity > 0 | ||||
251 | Rectangle { | ||||
252 | anchors.fill: parent | ||||
253 | color: Kirigami.Theme.backgroundColor | ||||
254 | opacity: 0.7 | ||||
255 | } | ||||
256 | QtControls.BusyIndicator { | ||||
257 | anchors { | ||||
258 | horizontalCenter: parent.horizontalCenter | ||||
259 | bottom: parent.verticalCenter | ||||
260 | bottomMargin: Kirigami.Units.largeSpacing | ||||
261 | } | ||||
262 | running: newStuffEngine.isLoading | ||||
263 | } | ||||
264 | QtControls.Label { | ||||
265 | anchors { | ||||
266 | top: parent.verticalCenter | ||||
267 | left: parent.left | ||||
268 | right: parent.right | ||||
269 | margins: Kirigami.Units.largeSpacing | ||||
270 | } | ||||
271 | horizontalAlignment: Text.AlignHCenter | ||||
272 | text: newStuffEngine.statusMessage | ||||
273 | } | ||||
274 | } | ||||
232 | } | 275 | } |