Members of the KDE Community are recommended to subscribe to the kde-community mailing list at to allow them to participate in important discussions and receive other important announcements

Commit a6929de8 authored by Frederik Gladhorn's avatar Frederik Gladhorn Committed by Frederik Gladhorn

QMLScreen: do not declare the engine a member

Summary: There is no need for this, the only use of the engine is when creating QQMLOutputComponent.

Reviewers: #plasma, romangg

Reviewed By: #plasma, romangg

Subscribers: broulik, romangg, plasma-devel

Tags: #plasma

Differential Revision:
parent ff717c0a
......@@ -82,9 +82,7 @@ void QMLScreen::setConfig(const KScreen::ConfigPtr &config)
void QMLScreen::addOutput(const KScreen::OutputPtr &output)
//QQuickItem *container = findChild<QQuickItem*>(QLatin1String("outputContainer"));
QMLOutputComponent comp(m_engine, this);
QMLOutputComponent comp(qmlEngine(this), this);
QMLOutput *qmloutput = comp.createForOutput(output);
if (!qmloutput) {
qWarning() << "Failed to create QMLOutput";
......@@ -350,8 +348,3 @@ void QMLScreen::updateOutputsPlacement()
void QMLScreen::setEngine(QQmlEngine* engine)
m_engine = engine;
......@@ -52,9 +52,6 @@ class QMLScreen : public QQuickItem
READ outputScale
NOTIFY outputScaleChanged)
Q_PROPERTY(QQmlEngine* engine
MEMBER m_engine)
explicit QMLScreen(QQuickItem *parent = nullptr);
~QMLScreen() override;
......@@ -73,7 +70,6 @@ class QMLScreen : public QQuickItem
void setConfig(const KScreen::ConfigPtr &config);
void updateOutputsPlacement();
void setEngine(QQmlEngine* engine);
void setActiveOutput(QMLOutput *output);
......@@ -110,7 +106,6 @@ class QMLScreen : public QQuickItem
int m_connectedOutputsCount = 0;
int m_enabledOutputsCount = 0;
QQmlEngine* m_engine = nullptr;
QMLOutput *m_leftmost = nullptr;
QMLOutput *m_topmost = nullptr;
QMLOutput *m_rightmost = nullptr;
......@@ -188,8 +188,6 @@ void Widget::loadQml()
if (!mScreen) {
connect(mScreen, &QMLScreen::focusedOutputChanged,
this, &Widget::slotFocusedOutputChanged);
connect(rootObject->findChild<QObject*>(QStringLiteral("identifyButton")), SIGNAL(clicked()),
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment