[prev in list] [next in list] [prev in thread] [next in thread]
List: kde-commits
Subject: [kde-workspace/plasma/sreich/sal-qml] plasma/netbook/containments/sal/package/contents/ui: add highl
From: Shaun Reich <shaun.reich () kdemail ! net>
Date: 2012-02-29 23:12:12
Message-ID: 20120229231212.5868EA60A9 () git ! kde ! org
[Download RAW message or body]
Git commit d9e2f2289c0aebf2fc77a2899157fda9f57726a6 by Shaun Reich.
Committed on 01/03/2012 at 00:02.
Pushed by sreich into branch 'plasma/sreich/sal-qml'.
add highlight item to the gridview, instead of making it per Result item
M +0 -20 plasma/netbook/containments/sal/package/contents/ui/Result.qml
M +23 -7 plasma/netbook/containments/sal/package/contents/ui/ResultsView.qml
http://commits.kde.org/kde-workspace/d9e2f2289c0aebf2fc77a2899157fda9f57726a6
diff --git a/plasma/netbook/containments/sal/package/contents/ui/Result.qml \
b/plasma/netbook/containments/sal/package/contents/ui/Result.qml index \
78499e7..69ed2d9 100644
--- a/plasma/netbook/containments/sal/package/contents/ui/Result.qml
+++ b/plasma/netbook/containments/sal/package/contents/ui/Result.qml
@@ -66,18 +66,7 @@ Item {
}
}
- PlasmaComponents.Highlight {
- id: highlighter
- anchors.fill: parent
- hover: true
- opacity: 0
- Behavior on opacity {
- NumberAnimation {
- duration: 150
- }
- }
- }
MouseArea {
anchors.fill: parent
@@ -91,14 +80,5 @@ Item {
wasClicked = false
wasClicked = true
}
-
- onEntered: {
- highlighter.opacity = 1
- }
-
- onExited: {
- highlighter.opacity = 0
- }
-
}
}
\ No newline at end of file
diff --git a/plasma/netbook/containments/sal/package/contents/ui/ResultsView.qml \
b/plasma/netbook/containments/sal/package/contents/ui/ResultsView.qml index \
ed1db4b..ce93218 100644
--- a/plasma/netbook/containments/sal/package/contents/ui/ResultsView.qml
+++ b/plasma/netbook/containments/sal/package/contents/ui/ResultsView.qml
@@ -46,13 +46,9 @@ Item {
rightMargin: resultItemHeight
}
-// move: Transition {
-// PropertyAnimation {
-// properties: "x,y"
-// easing.type: Easing.InOutQuad
-// }
-// }
-//
+ highlightFollowsCurrentItem: true
+
+ highlight: highlight
delegate: Result {
id: result
currentText: model["label"]
@@ -63,6 +59,15 @@ Item {
print(result.currentId)
// appIndexToRun = result.currentIndex:
}
+
+ MouseArea {
+ anchors.fill: parent
+ hoverEnabled: true
+
+ onEntered: {
+ gridView.currentIndex = index
+ }
+ }
}
}
}
@@ -76,4 +81,15 @@ Item {
bottom: parent.bottom
}
}
+
+ Component {
+ id: highlight
+
+ PlasmaComponents.Highlight {
+ id: highlighter
+ // anchors.fill: parent
+ hover: true
+ }
+
+ }
}
\ No newline at end of file
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic