-
Notifications
You must be signed in to change notification settings - Fork 65
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
4 changed files
with
66 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,55 @@ | ||
/*************************************************************************** | ||
* * | ||
* This program is free software; you can redistribute it and/or modify * | ||
* it under the terms of the GNU General Public License as published by * | ||
* the Free Software Foundation; either version 2 of the License, or * | ||
* (at your option) any later version. * | ||
* * | ||
***************************************************************************/ | ||
|
||
import QtQuick | ||
import QtQuick.Controls | ||
import QtQuick.Controls.Basic | ||
import Qt5Compat.GraphicalEffects | ||
import "../Style.js" as Style | ||
import "." | ||
|
||
Item { | ||
id: control | ||
|
||
width: text.width | ||
height: Style.commonItemHeight | ||
visible: control.text.length > 0 | ||
|
||
signal clicked | ||
|
||
required property string text | ||
property color bgColor: Style.positive | ||
property color textColor: Style.forest | ||
|
||
Rectangle { | ||
width: parent.width | ||
height: parent.height | ||
radius: control.height / 2 | ||
color: control.bgColor | ||
|
||
layer.enabled: true | ||
layer.effect: MMShadow {} | ||
|
||
Text { | ||
id: text | ||
|
||
anchors.centerIn: parent | ||
color: control.textColor | ||
text: control.text | ||
font: Qt.font(Style.t3) | ||
leftPadding: Style.commonSpacing | ||
rightPadding: Style.commonSpacing | ||
} | ||
|
||
MouseArea { | ||
anchors.fill: parent | ||
onClicked: control.clicked() | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
df7996e
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
iOS - version 23.10.470911 just submitted!