From 33c5f4c3ad73fa2e75fe7ba69f5359e69adb212f Mon Sep 17 00:00:00 2001 From: Friedemann Kleint Date: Tue, 5 Sep 2017 10:13:04 +0200 Subject: Check for empty style returned from environment Fix warning "Empty filename passed to function" when running Qt Creator 4.4 against Qt 5.10 (see qtbase: 0dee566e98f5ff4f224e596de1c04de4f9685df4). Change-Id: I0b71a873245a28ef972c105e7d41347e6b0fb38a Reviewed-by: J-P Nurmi --- src/controls/Private/qquickcontrolsettings.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/controls') diff --git a/src/controls/Private/qquickcontrolsettings.cpp b/src/controls/Private/qquickcontrolsettings.cpp index c7f641cc..d8cfdaed 100644 --- a/src/controls/Private/qquickcontrolsettings.cpp +++ b/src/controls/Private/qquickcontrolsettings.cpp @@ -222,7 +222,7 @@ QQuickControlSettings1::QQuickControlSettings1(QQmlEngine *engine) // If the style name is a path.. const QString styleNameFromEnvVar = styleEnvironmentVariable(); - if (QFile::exists(styleNameFromEnvVar)) { + if (!styleNameFromEnvVar.isEmpty() && QFile::exists(styleNameFromEnvVar)) { StyleData styleData; styleData.m_styleDirPath = styleNameFromEnvVar; m_styleMap[m_name] = styleData; -- cgit v1.2.1 From 2430cc139437dac021b6028d8ba8799c50bd0e6c Mon Sep 17 00:00:00 2001 From: Frederik Gladhorn Date: Tue, 10 Oct 2017 10:29:50 +0200 Subject: Update slider handle position when maximum changes This is exactly the same as the minimum change, when the maximum is changed, the handle position needs to be re-evaluated. Task-number: QTBUG-63354 Change-Id: I13a67451190a3bb7915afe8e89501097c1dd3301 Reviewed-by: Mitch Curtis --- src/controls/Slider.qml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/controls') diff --git a/src/controls/Slider.qml b/src/controls/Slider.qml index a90bc022..aa5fe07e 100644 --- a/src/controls/Slider.qml +++ b/src/controls/Slider.qml @@ -177,10 +177,10 @@ Control { /*! \internal The extra arguments positionAtMinimum and positionAtMaximum are there to force re-evaluation of the handle position when the constraints change (QTBUG-41255), - and the same for range.minimumValue (QTBUG-51765). + and the same for range.minimumValue (QTBUG-51765) and range.maximumValue (QTBUG-63354). */ property real __handlePos: range.valueForPosition(__horizontal ? fakeHandle.x : fakeHandle.y, - range.positionAtMinimum, range.positionAtMaximum, range.minimumValue) + range.positionAtMinimum, range.positionAtMaximum, range.minimumValue, range.maximumValue) activeFocusOnTab: true -- cgit v1.2.1