Compare commits

...

1 Commits

Author SHA1 Message Date
Alexander Lohnau
78e0edfb7e Fix build for old KNewStuff versions 2022-10-17 10:52:44 +02:00
4 changed files with 6 additions and 4 deletions

View File

@@ -45,7 +45,7 @@ UrlListParamWidget::UrlListParamWidget(std::shared_ptr<AssetParameterModel> mode
});
#else
m_knsbutton = new QToolButton(this);
m_knsbutton->setIcon(QIcon::fromTheme(QStringLiteral("edit-download"));
m_knsbutton->setIcon(QIcon::fromTheme(QStringLiteral("edit-download")));
connect(m_knsbutton, &QToolButton::clicked, this, &UrlListParamWidget::downloadNewItems);
#endif
m_value_box->layout()->addWidget(m_knsbutton);

View File

@@ -12,6 +12,8 @@
#include <knewstuff_version.h>
#if KNEWSTUFF_VERSION >= QT_VERSION_CHECK(5, 91, 0)
#include <KNSWidgets/Button>
#else
#include <QToolButton>
#endif
class AssetParameterModel;

View File

@@ -185,9 +185,9 @@ RenderWidget::RenderWidget(bool enableProxy, QWidget *parent)
});
#else
m_knsbutton = new QToolButton(this);
m_knsbutton->setIcon(QIcon::fromTheme(QStringLiteral("edit-download"));
m_knsbutton->setIcon(QIcon::fromTheme(QStringLiteral("edit-download")));
m_knsbutton->setAutoRaise(true);
connect(m_view.buttonDownload, &QAbstractButton::clicked, this, [&]() {
connect(m_knsbutton, &QAbstractButton::clicked, this, [&]() {
if (pCore->getNewStuff(QStringLiteral(":data/kdenlive_renderprofiles.knsrc")) > 0) {
parseProfiles();
}

View File

@@ -3412,7 +3412,7 @@ void MainWindow::slotResizeItemEnd()
getMainTimeline()->controller()->setOutPoint(m_activeTool == ToolType::RippleTool);
}
#if KXMLGUI_VERSION < QT_VERSION_CHECK(5, 98, 0)
#if KNEWSTUFF_VERSION < QT_VERSION_CHECK(5, 98, 0)
int MainWindow::getNewStuff(const QString &configFile)
{
KNS3::QtQuickDialogWrapper dialog(configFile);