Remove some uses on QDesktopWidget
ClosedPublic

Authored by apol on Jul 25 2019, 12:42 PM.

Details

Summary

Adds an unnecessary dependency to QtWidgets and forces some round-trips to the X server that we don't need.

Test Plan

Been using it for some days

Diff Detail

Repository
R119 Plasma Desktop
Lint
Automatic diff as part of commit; lint not applicable.
Unit
Automatic diff as part of commit; unit tests not applicable.
apol created this revision.Jul 25 2019, 12:42 PM
Restricted Application added a project: Plasma. · View Herald TranscriptJul 25 2019, 12:42 PM
Restricted Application added a subscriber: plasma-devel. · View Herald Transcript
apol requested review of this revision.Jul 25 2019, 12:42 PM
davidedmundson requested changes to this revision.Jul 25 2019, 9:14 PM
davidedmundson added a subscriber: davidedmundson.

concept ++

applets/pager/plugin/pagermodel.cpp
120

we need this connection for screens that already exist when this code runs

containments/desktop/plugins/folder/foldermodel.cpp
1640

KNewFileMenu.cpp in the constructor
1148 d->m_parentWidget = qobject_cast<QWidget *>(parent);

without a transient parent we probably have focus issues?

This revision now requires changes to proceed.Jul 25 2019, 9:14 PM
apol marked an inline comment as done.Jul 26 2019, 12:11 AM
apol added inline comments.
containments/desktop/plugins/folder/foldermodel.cpp
1640

It doesn't show any issues that I can see.
Also the QDesktopWidget isn't an actual widget so I'm not sure what it's supposed to be bringing.

apol updated this revision to Diff 62582.Jul 26 2019, 12:11 AM

addressed comment

hein added a subscriber: hein.Jul 26 2019, 8:40 AM
hein added inline comments.
applets/pager/plugin/pagermodel.cpp
123

Missing braces around single-line block and no const

apol updated this revision to Diff 62725.Jul 29 2019, 10:46 AM

Add eike's braces

apol marked an inline comment as done.Jul 29 2019, 10:47 AM
davidedmundson accepted this revision.Jul 29 2019, 10:58 AM
This revision is now accepted and ready to land.Jul 29 2019, 10:58 AM
This revision was automatically updated to reflect the committed changes.