r24906 by jghali - Qt6: fix some deprecation warnings
scribus-commit
scribus-commit at lists.scribus.net
Fri Feb 4 22:47:22 UTC 2022
Author: jghali
Date: Fri Feb 4 22:47:21 2022
New Revision: 24906
URL: http://scribus.net/websvn/listing.php?repname=Scribus&sc=1&rev=24906
Log:
Qt6: fix some deprecation warnings
Modified:
trunk/Scribus/scribus/scribusapp.cpp
trunk/Scribus/scribus/ui/charselect.cpp
trunk/Scribus/scribus/ui/storyeditor.cpp
Modified: trunk/Scribus/scribus/scribusapp.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=24906&path=/trunk/Scribus/scribus/scribusapp.cpp
==============================================================================
--- trunk/Scribus/scribus/scribusapp.cpp (original)
+++ trunk/Scribus/scribus/scribusapp.cpp Fri Feb 4 22:47:21 2022
@@ -502,7 +502,7 @@
}
//CB: This might need adjusting for qm files distribution locations
- if (transQt->load("qt_" + lang, QLibraryInfo::location(QLibraryInfo::TranslationsPath)))
+ if (transQt->load("qt_" + lang, QLibraryInfo::path(QLibraryInfo::TranslationsPath)))
loadedQt = true;
if (trans->load(QString("scribus." + lang), path))
loadedScribus = true;
Modified: trunk/Scribus/scribus/ui/charselect.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=24906&path=/trunk/Scribus/scribus/ui/charselect.cpp
==============================================================================
--- trunk/Scribus/scribus/ui/charselect.cpp (original)
+++ trunk/Scribus/scribus/ui/charselect.cpp Fri Feb 4 22:47:21 2022
@@ -179,7 +179,7 @@
// QVariant, so we should make sure first that we can convert to QStringList.
// Otherwise clear the status label
QVariant tmp = index.data(Qt::StatusTipRole);
- if ( !tmp.canConvert(QMetaType::QStringList) )
+ if (!tmp.canConvert<QStringList>())
{
m_statusLabel->setText(QString());
return;
Modified: trunk/Scribus/scribus/ui/storyeditor.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=24906&path=/trunk/Scribus/scribus/ui/storyeditor.cpp
==============================================================================
--- trunk/Scribus/scribus/ui/storyeditor.cpp (original)
+++ trunk/Scribus/scribus/ui/storyeditor.cpp Fri Feb 4 22:47:21 2022
@@ -1678,12 +1678,12 @@
void StoryEditor::initActions()
{
//File Menu
- seActions.insert("fileNew", new ScrAction("16/document-new.png", "22/document-new.png", "", Qt::CTRL+Qt::Key_N, this));
+ seActions.insert("fileNew", new ScrAction("16/document-new.png", "22/document-new.png", "", Qt::CTRL|Qt::Key_N, this));
seActions.insert("fileRevert", new ScrAction("reload16.png", "reload.png", "", QKeySequence(), this));
seActions.insert("fileSaveToFile", new ScrAction("16/document-save.png", "22/document-save.png", "", QKeySequence(), this));
seActions.insert("fileLoadFromFile", new ScrAction("16/document-open.png", "22/document-open.png", "", QKeySequence(), this));
- seActions.insert("fileSaveDocument", new ScrAction("", Qt::CTRL+Qt::Key_S, this));
- seActions.insert("fileUpdateAndExit", new ScrAction("ok.png", "ok22.png", "", Qt::CTRL+Qt::Key_W, this));
+ seActions.insert("fileSaveDocument", new ScrAction("", Qt::CTRL|Qt::Key_S, this));
+ seActions.insert("fileUpdateAndExit", new ScrAction("ok.png", "ok22.png", "", Qt::CTRL|Qt::Key_W, this));
seActions.insert("fileExit", new ScrAction("exit.png", "exit22.png", "", QKeySequence(), this));
connect( seActions["fileNew"], SIGNAL(triggered()), this, SLOT(Do_new()) );
@@ -1695,15 +1695,15 @@
connect( seActions["fileExit"], SIGNAL(triggered()), this, SLOT(Do_leave()) );
//Edit Menu
- seActions.insert("editCut", new ScrAction("16/edit-cut.png", QString(), "", Qt::CTRL+Qt::Key_X, this));
- seActions.insert("editCopy", new ScrAction("16/edit-copy.png", QString(), "", Qt::CTRL+Qt::Key_C, this));
- seActions.insert("editPaste", new ScrAction("16/edit-paste.png", QString(), "", Qt::CTRL+Qt::Key_V, this));
+ seActions.insert("editCut", new ScrAction("16/edit-cut.png", QString(), "", Qt::CTRL|Qt::Key_X, this));
+ seActions.insert("editCopy", new ScrAction("16/edit-copy.png", QString(), "", Qt::CTRL|Qt::Key_C, this));
+ seActions.insert("editPaste", new ScrAction("16/edit-paste.png", QString(), "", Qt::CTRL|Qt::Key_V, this));
seActions.insert("editClear", new ScrAction("16/edit-delete.png", QString(), "", Qt::Key_Delete, this));
- seActions.insert("editSelectAll", new ScrAction("16/edit-select-all.png", QString(), "", Qt::CTRL+Qt::Key_A, this));
- seActions.insert("editSearchReplace", new ScrAction("16/edit-find-replace.png", QString(), "", Qt::CTRL+Qt::Key_F, this));
+ seActions.insert("editSelectAll", new ScrAction("16/edit-select-all.png", QString(), "", Qt::CTRL|Qt::Key_A, this));
+ seActions.insert("editSearchReplace", new ScrAction("16/edit-find-replace.png", QString(), "", Qt::CTRL|Qt::Key_F, this));
//seActions.insert("editEditStyle", new ScrAction("", QKeySequence(), this));
seActions.insert("editFontPreview", new ScrAction("", QKeySequence(), this));
- seActions.insert("editUpdateFrame", new ScrAction("compfile16.png", "compfile.png", "", Qt::CTRL+Qt::Key_U, this));
+ seActions.insert("editUpdateFrame", new ScrAction("compfile16.png", "compfile.png", "", Qt::CTRL|Qt::Key_U, this));
connect( seActions["editCut"], SIGNAL(triggered()), this, SLOT(Do_cut()) );
connect( seActions["editCopy"], SIGNAL(triggered()), this, SLOT(Do_copy()) );
More information about the scribus-commit
mailing list