[LyX/2.3.x] Fix deprecation warning

Juergen Spitzmueller spitz at lyx.org
Sat Mar 13 08:11:56 UTC 2021


commit 548c165ae0ed4ccdf4a39ff59ca5a59397689458
Author: Juergen Spitzmueller <spitz at lyx.org>
Date:   Sat Mar 13 09:17:21 2021 +0100

    Fix deprecation warning
---
 src/frontends/qt4/GuiWorkArea.cpp |    5 +++++
 1 files changed, 5 insertions(+), 0 deletions(-)

diff --git a/src/frontends/qt4/GuiWorkArea.cpp b/src/frontends/qt4/GuiWorkArea.cpp
index 2352ecd..a16a9c8 100644
--- a/src/frontends/qt4/GuiWorkArea.cpp
+++ b/src/frontends/qt4/GuiWorkArea.cpp
@@ -1956,8 +1956,13 @@ public:
 		filename_ = (filename.extension() == "lyx") ?
 			toqstr(filename.onlyFileNameWithoutExt())
 			: toqstr(filename.onlyFileName());
+#if (QT_VERSION >= QT_VERSION_CHECK(5, 15, 0))
+		postfix_ = toqstr(filename.absoluteFilePath()).
+			split("/", Qt::SkipEmptyParts);
+#else
 		postfix_ = toqstr(filename.absoluteFilePath()).
 			split("/", QString::SkipEmptyParts);
+#endif
 		postfix_.pop_back();
 		abs_ = toqstr(filename.absoluteFilePath());
 		dottedPrefix_ = false;


More information about the lyx-cvs mailing list