forked from guoyunhe/unwallpaper
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathmain.qml
121 lines (102 loc) · 2.56 KB
/
main.qml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
import QtQuick 2.7
import QtQuick.Window 2.2
import QtGraphicalEffects 1.0
import Unwallpaper 1.0
Window {
visible: true
width: 960
height: 640
title: "Unwallpaper"
Item {
id: navbar
width: parent.width
height: 40
clip: true
z: 1
FastBlur {
width: parent.width
height: content.height
source: content
radius: 32
}
Rectangle {
width: parent.width
height: parent.height
color: "#AAFFFFFF"
}
Row {
anchors.top: parent.top
anchors.topMargin: 10
anchors.left: parent.left
anchors.leftMargin: 20
spacing: 20
Nav {
id: latestPhotoNav
//: Navbar entry
text: qsTr("Latest")
active: true
}
Nav {
id: popularPhotoNav
//: Navbar entry
text: qsTr("Popular")
active: false
}
Nav {
id: curatedPhotoNav
//: Navbar entry
text: qsTr("Curated")
active: false
}
Nav {
id: downloadedPhotoNav
//: Navbar entry
text: qsTr("Downloaded")
active: false
}
Nav {
id: aboutPageNav
//: Navbar entry
text: qsTr("About")
active: false
}
}
}
Item {
id: content
width: parent.width
height: parent.height
PhotoList {
id: latestPhotoList
visible: latestPhotoNav.active
model: PhotoListModel {
order: PhotoListModel.Latest
}
}
PhotoList {
id: popularPhotoList
visible: popularPhotoNav.active
model: PhotoListModel {
order: PhotoListModel.Popular
}
}
PhotoList {
id: curatedPhotoList
visible: curatedPhotoNav.active
model: PhotoListModel {
order: PhotoListModel.Latest
curated: true
}
}
PhotoList {
id: downloadedPhotoList
visible: downloadedPhotoNav.active
model: LocalPhotoListModel {
}
}
AboutPage {
id: aboutPage
visible: aboutPageNav.active
}
}
}