summaryrefslogtreecommitdiffstats
path: root/examples
diff options
context:
space:
mode:
authorTuomo Pelkonen <tuomo.pelkonen@gmail.com>2021-02-15 12:07:48 +0200
committerQt Cherry-pick Bot <cherrypick_bot@qt-project.org>2021-02-26 05:21:45 +0000
commit751f755213aedcfe7c36aeebf1e2ae6a010d0bde (patch)
treee94a426deb815692b01876203558b3ca73968ee8 /examples
parent95ebd340b9ddce6ee3abc2043e103647a73ede5b (diff)
Fix layout and signal handling in QML apps
Task-number: QTBUG-90664 Change-Id: I181a3b3b2a1801665a0d876a837054aa10425c0d Reviewed-by: Tomi Korpipää <tomi.korpipaa@qt.io> (cherry picked from commit 9cb0e5714182df7f7d6b4fb291ffb83b614750d5) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
Diffstat (limited to 'examples')
-rw-r--r--examples/datavisualization/qmllegend/qml/qmllegend/LegendItem.qml4
1 files changed, 2 insertions, 2 deletions
diff --git a/examples/datavisualization/qmllegend/qml/qmllegend/LegendItem.qml b/examples/datavisualization/qmllegend/qml/qmllegend/LegendItem.qml
index 5d63bde2..714b1e78 100644
--- a/examples/datavisualization/qmllegend/qml/qmllegend/LegendItem.qml
+++ b/examples/datavisualization/qmllegend/qml/qmllegend/LegendItem.qml
@@ -104,8 +104,8 @@ Rectangle {
//! [4]
Connections {
target: series
- onSelectedBarChanged: {
- if (position != series.invalidSelectionPosition) {
+ function onSelectedBarChanged(position) {
+ if (position !== series.invalidSelectionPosition) {
previousSelection = position
}
}