[education/rkward] rkward/misc: Compilation fix for qt < 5.10

Thomas Friedrichsmeier null at kde.org
Wed Mar 9 22:10:00 GMT 2022


Git commit 6d2270595e453cece3924abb52c97805a666be71 by Thomas Friedrichsmeier.
Committed on 09/03/2022 at 22:09.
Pushed by tfry into branch 'master'.

Compilation fix for qt < 5.10

M  +5    -0    rkward/misc/rkoutputdirectory.cpp

https://invent.kde.org/education/rkward/commit/6d2270595e453cece3924abb52c97805a666be71

diff --git a/rkward/misc/rkoutputdirectory.cpp b/rkward/misc/rkoutputdirectory.cpp
index d527bdc2..f5acab02 100644
--- a/rkward/misc/rkoutputdirectory.cpp
+++ b/rkward/misc/rkoutputdirectory.cpp
@@ -90,7 +90,12 @@ RKOutputDirectory* RKOutputDirectory::findOutputByWorkPath(const QString& workpa
 
 	if (workpath.endsWith("index.html")) {
 		QString wp = workpath;
+#if QT_VERSION >= QT_VERSION_CHECK(5,10,0)
 		return(outputs.value(wp.chopped(11)));  // index.html, including pathsep
+#else
+		wp.chop(11);
+		return(outputs.value(wp));
+#endif
 	}
 	return nullptr;
 }


More information about the rkward-tracker mailing list