diff options
author | J-P Nurmi <jpnurmi@theqtcompany.com> | 2015-12-03 13:21:04 +0100 |
---|---|---|
committer | J-P Nurmi <jpnurmi@theqtcompany.com> | 2015-12-03 17:18:14 +0000 |
commit | 8d44f46e65ea38155b70c069a180bf0755bd9289 (patch) | |
tree | f19b8a8954c816c3864b7c63f21266869c3c13f7 /src/imports/controls/universal/ItemDelegate.qml | |
parent | 5801239f70614e94f4a977b4122079c4ce2c232c (diff) |
ItemDelegate: implement highlighted state
Change-Id: I6c4cdd97fcdaa86c2bdc5a8f465c2d9b6eddcf13
Reviewed-by: Mitch Curtis <mitch.curtis@theqtcompany.com>
Diffstat (limited to 'src/imports/controls/universal/ItemDelegate.qml')
-rw-r--r-- | src/imports/controls/universal/ItemDelegate.qml | 12 |
1 files changed, 10 insertions, 2 deletions
diff --git a/src/imports/controls/universal/ItemDelegate.qml b/src/imports/controls/universal/ItemDelegate.qml index d9156177..a5330059 100644 --- a/src/imports/controls/universal/ItemDelegate.qml +++ b/src/imports/controls/universal/ItemDelegate.qml @@ -87,8 +87,16 @@ T.ItemDelegate { //! [background] background: Rectangle { - visible: control.pressed - color: control.Universal.listMediumColor + visible: control.pressed || control.highlighted || control.activeFocus + color: control.pressed ? control.Universal.listMediumColor : control.Universal.altMediumLowColor + Rectangle { + width: parent.width + height: parent.height + visible: control.activeFocus || control.highlighted + color: control.Universal.accentColor + opacity: control.Universal.theme === Universal.Light ? 0.4 : 0.6 + } + } //! [background] } |