Merge pull request #117

142e348 Transfer: use the new error LineEdit property to highlight bad fields (moneromooo.monero)
b97d0a9 LineEdit: add an error property (moneromooo.monero)
5fb4e89 Transfer: remove spammy debug traces (moneromooo.monero)
This commit is contained in:
Riccardo Spagni
2016-11-09 20:43:33 +02:00
2 changed files with 28 additions and 6 deletions

View File

@@ -35,10 +35,18 @@ Item {
property alias readOnly : input.readOnly
property alias cursorPosition: input.cursorPosition
property int fontSize: 18
property bool error: false
height: 37
function getColor(error) {
if (error)
return "#FFDDDD"
else
return "#FFFFFF"
}
Rectangle {
anchors.fill: parent
anchors.bottomMargin: 1
@@ -49,7 +57,7 @@ Item {
Rectangle {
anchors.fill: parent
anchors.topMargin: 1
color: "#FFFFFF"
color: getColor(error)
//radius: 4
}