Changeset View
Changeset View
Standalone View
Standalone View
kcms/desktoptheme/package/contents/ui/ThemePreview.qml
Show All 14 Lines | 1 | /* | |||
---|---|---|---|---|---|
15 | the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, | 15 | the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, | ||
16 | Boston, MA 02110-1301, USA. | 16 | Boston, MA 02110-1301, USA. | ||
17 | */ | 17 | */ | ||
18 | import QtQuick 2.4 | 18 | import QtQuick 2.4 | ||
19 | import QtQuick.Layouts 1.1 | 19 | import QtQuick.Layouts 1.1 | ||
20 | import org.kde.plasma.core 2.0 as PlasmaCore | 20 | import org.kde.plasma.core 2.0 as PlasmaCore | ||
21 | import org.kde.kirigami 2.4 as Kirigami | 21 | import org.kde.kirigami 2.4 as Kirigami | ||
22 | import org.kde.plasma.components 2.0 as PlasmaComponents | 22 | import org.kde.plasma.components 2.0 as PlasmaComponents | ||
23 | import org.kde.private.kcms.desktoptheme 1.0 as Private | ||||
23 | 24 | | |||
24 | Item { | 25 | Item { | ||
25 | id: root | 26 | id: root | ||
26 | property string themeName | 27 | property string themeName | ||
27 | 28 | | |||
28 | Item { | 29 | Item { | ||
29 | id: backgroundMask | 30 | id: backgroundMask | ||
30 | anchors.fill: parent | 31 | anchors.fill: parent | ||
▲ Show 20 Lines • Show All 140 Lines • ▼ Show 20 Line(s) | 171 | PlasmaCore.SvgItem { | |||
171 | anchors.fill: face | 172 | anchors.fill: face | ||
172 | svg: clockSvg | 173 | svg: clockSvg | ||
173 | elementId: "Glass" | 174 | elementId: "Glass" | ||
174 | width: naturalSize.width * clock.svgScale | 175 | width: naturalSize.width * clock.svgScale | ||
175 | height: naturalSize.height * clock.svgScale | 176 | height: naturalSize.height * clock.svgScale | ||
176 | } | 177 | } | ||
177 | } | 178 | } | ||
178 | Kirigami.Icon { | 179 | Kirigami.Icon { | ||
179 | visible: model.followsSystemColors | 180 | visible: model.colorType === Private.ThemesModel.FollowsColorTheme | ||
ervin: Better use === with this bloody javascript | |||||
180 | source: "color-profile" | 181 | source: "color-profile" | ||
181 | width: Kirigami.Units.iconSizes.smallMedium | 182 | width: Kirigami.Units.iconSizes.smallMedium | ||
182 | height: width | 183 | height: width | ||
183 | Layout.alignment: Qt.AlignRight && Qt.AlignTop | 184 | Layout.alignment: Qt.AlignRight && Qt.AlignTop | ||
184 | } | 185 | } | ||
185 | } | 186 | } | ||
186 | 187 | | |||
187 | Component.onCompleted: { | 188 | Component.onCompleted: { | ||
188 | kcm.applyPlasmaTheme(root, themeName); | 189 | kcm.applyPlasmaTheme(root, themeName); | ||
189 | } | 190 | } | ||
190 | } | 191 | } |
Better use === with this bloody javascript