diff options
author | Thomas Hartmann <Thomas.Hartmann@theqtcompany.com> | 2015-01-22 10:12:23 +0100 |
---|---|---|
committer | Tim Jenssen <tim.jenssen@theqtcompany.com> | 2015-01-22 10:23:51 +0100 |
commit | 39107ca29832c009f39c4c811d7288f64a0cad7d (patch) | |
tree | fa5cdd05dc30918a6cacdeecd6210164ec22b879 | |
parent | e421b348bb7b9d9e3bc46d6e927257327b9fd9bb (diff) | |
download | qt-creator-39107ca29832c009f39c4c811d7288f64a0cad7d.tar.gz |
QmlDesigner.PropertyEditor: Remove Slider from SpinBox
The integrated slider in a SpinBox did not work well.
Sliders do crash on Yosemite if maximumValue and minimumValue
are the same.
Change-Id: If1a5fe5109591bc8198c5659f10e73ebaeb8c636
Task-number: QTCREATORBUG-13842
Reviewed-by: Tim Jenssen <tim.jenssen@theqtcompany.com>
-rw-r--r-- | share/qtcreator/qmldesigner/propertyEditorQmlSources/HelperWidgets/SliderSpinBox.qml | 73 | ||||
-rw-r--r-- | share/qtcreator/qmldesigner/propertyEditorQmlSources/HelperWidgets/SpinBox.qml | 19 |
2 files changed, 0 insertions, 92 deletions
diff --git a/share/qtcreator/qmldesigner/propertyEditorQmlSources/HelperWidgets/SliderSpinBox.qml b/share/qtcreator/qmldesigner/propertyEditorQmlSources/HelperWidgets/SliderSpinBox.qml index c0d6b92efe..7e25e7c81b 100644 --- a/share/qtcreator/qmldesigner/propertyEditorQmlSources/HelperWidgets/SliderSpinBox.qml +++ b/share/qtcreator/qmldesigner/propertyEditorQmlSources/HelperWidgets/SliderSpinBox.qml @@ -39,79 +39,6 @@ SpinBox { property color highlightColor: "orange" property color textColor: "#eee" - function showSlider() { - timer.stop() - timer2.start() - slider.opacity = 1; - } - - onHoveredChanged: { - if (hovered) - showSlider(); - } - - Slider { - id: slider - - anchors.left: parent.left - anchors.right: parent.right - anchors.top: parent.bottom - height: 10; - //opacity: 0 - - maximumValue: spinBox.maximumValue - minimumValue: spinBox.minimumValue - - value: spinBox.value - visible: false - - onValueChanged: { - spinBox.value = value - } - - Behavior on opacity { - PropertyAnimation { - duration: 100 - } - } - - onHoveredChanged: { - if (!hovered) { - timer.startTimer(); - } else { - timer2.stop() - timer.stop() - } - } - } - - Timer { - id: timer - repeat: false - function startTimer() { - if (!timer.running) - timer.start() - } - interval: 600 - - onTriggered: { - return - if (!slider.hovered) - slider.opacity = 0; - } - } - - Timer { - id: timer2 - repeat: false - interval: 1000 - onTriggered: { - return - if (!slider.hovered) - slider.opacity = 0; - } - } - style: CustomSpinBoxStyle { } diff --git a/share/qtcreator/qmldesigner/propertyEditorQmlSources/HelperWidgets/SpinBox.qml b/share/qtcreator/qmldesigner/propertyEditorQmlSources/HelperWidgets/SpinBox.qml index 01c5adc5f6..b9963ecae8 100644 --- a/share/qtcreator/qmldesigner/propertyEditorQmlSources/HelperWidgets/SpinBox.qml +++ b/share/qtcreator/qmldesigner/propertyEditorQmlSources/HelperWidgets/SpinBox.qml @@ -63,25 +63,6 @@ Controls.SpinBox { backendValue.value = value; } - Controls.Slider { - id: slider - - anchors.left: parent.left - anchors.right: parent.right - anchors.top: parent.bottom - height: 10 - visible: false - - maximumValue: spinBox.maximumValue - minimumValue: spinBox.minimumValue - - value: spinBox.value - - onValueChanged: { - spinBox.value = value - } - } - style: CustomSpinBoxStyle { } } |