Debian Codegraph @

src/app/qml/components/SettingsButton.qml

raw
1 /*
2 * Copyright (C) 2015 Canonical Ltd.
3 *
4 * This file is part of Lomiri Weather App
5 *
6 * Lomiri Weather App is free software: you can redistribute it and/or modify
7 * it under the terms of the GNU General Public License version 3 as
8 * published by the Free Software Foundation.
9 *
10 * Lomiri Weather App is distributed in the hope that it will be useful,
11 * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 * GNU General Public License for more details.
14 *
15 * You should have received a copy of the GNU General Public License
16 * along with this program. If not, see <http://www.gnu.org/licenses/>.
17 */
18
19 import QtQuick 2.12
20 import Lomiri.Components 1.3
21
22
23 AbstractButton {
24 id: settingsButton
25 objectName: "settingsButton"
26 height: width
27 width: units.gu(4)
28
29 onClicked: mainPageStack.push(Qt.resolvedUrl("../ui/SettingsPage.qml"))
30
31 Rectangle {
32 anchors.fill: parent
33 color: Theme.palette.selected.background
34 visible: parent.pressed
35 }
36
37 Icon {
38 anchors.centerIn: parent
39 color: theme.palette.normal.baseText
40 height: width
41 name: "settings"
42 width: units.gu(2.5)
43 }
44 }