Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Plasma
KWin
Commits
b372de8c
Commit
b372de8c
authored
Apr 22, 2021
by
Aleix Pol Gonzalez
🐧
Committed by
Aleix Pol Gonzalez
Apr 23, 2021
Browse files
Fix startup when running with ASAN
We can't call kwinApp() before KWin::Application hasn't been properly initialized.
parent
3b66e634
Changes
1
Hide whitespace changes
Inline
Side-by-side
src/plugins/qpa/integration.cpp
View file @
b372de8c
...
...
@@ -76,8 +76,15 @@ bool Integration::hasCapability(Capability cap) const
void
Integration
::
initialize
()
{
// The QPA is initialized before the platform plugin is loaded.
connect
(
kwinApp
(),
&
Application
::
platformCreated
,
this
,
&
Integration
::
handlePlatformCreated
);
// This method is called from QGuiApplication's constructor, before kwinApp is built
QTimer
::
singleShot
(
0
,
this
,
[
this
]
{
// The QPA is initialized before the platform plugin is loaded.
if
(
kwinApp
()
->
platform
())
{
handlePlatformCreated
();
}
else
{
connect
(
kwinApp
(),
&
Application
::
platformCreated
,
this
,
&
Integration
::
handlePlatformCreated
);
}
});
QPlatformIntegration
::
initialize
();
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment