Debian Codegraph @

app/ui/ActionButton.qml

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