Showing the changes to interface/src/scripting/WindowScriptingInterface.cpp (1 of 1 file). Show all
Unified · Split
| @@ -123,7 +123,7 @@ void WindowScriptingInterface::setPreviousBrowseLocation(const QString& location · 122 unmodified lines | ||
| 123 | 123 | /// \return QScriptValue file path as a string if one was selected, otherwise `QScriptValue::NullValue` |
| 124 | 124 | QScriptValue WindowScriptingInterface::browse(const QString& title, const QString& directory, const QString& nameFilter) { |
| 125 | 125 | QString path = directory; |
| 126 | − if (path == "") { | |
| 126 | + if (path.isEmpty()) { | |
| 127 | 127 | path = getPreviousBrowseLocation(); |
| 128 | 128 | } |
| 129 | 129 | #ifndef Q_OS_WIN |
| @@ -144,7 +144,7 @@ QScriptValue WindowScriptingInterface::browse(const QString& title, const QStrin · 14 unmodified lines | ||
| 144 | 144 | /// \return QScriptValue file path as a string if one was selected, otherwise `QScriptValue::NullValue` |
| 145 | 145 | QScriptValue WindowScriptingInterface::save(const QString& title, const QString& directory, const QString& nameFilter) { |
| 146 | 146 | QString path = directory; |
| 147 | − if (path == "") { | |
| 147 | + if (path.isEmpty()) { | |
| 148 | 148 | path = getPreviousBrowseLocation(); |
| 149 | 149 | } |
| 150 | 150 | #ifndef Q_OS_WIN |