summaryrefslogtreecommitdiffstats
path: root/examples/demos/coffee/CustomButton.qml
blob: e19ffa796d23d105e0f13b133afd2fe0824f406a (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
// Copyright (C) 2023 The Qt Company Ltd.
// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR BSD-3-Clause

CustomButtonForm {
    rectangle.gradient: if (buttonColor == "grey"
                                && Colors.currentTheme == Colors.dark) {
                            Colors.darkButtonGradient
                        } else if (buttonColor == "grey"
                                   && Colors.currentTheme == Colors.light) {
                            Colors.lightButtonGradient
                        } else {
                            Colors.greenButtonGradient
                        }
}