libinput: Make sure we don't crash if we start without an output
This commit is contained in:
parent
4dca6408c2
commit
5f16757090
1 changed files with 4 additions and 1 deletions
|
@ -477,7 +477,10 @@ void Connection::processEvents()
|
|||
if (workspace()) {
|
||||
#ifndef KWIN_BUILD_TESTING
|
||||
auto client = workspace()->activeClient();
|
||||
const auto *output = static_cast<AbstractWaylandOutput *>(client ? client->output() : tte->device()->output());
|
||||
auto *output = static_cast<AbstractWaylandOutput *>(client ? client->output() : tte->device()->output());
|
||||
if (!output) {
|
||||
output = static_cast<AbstractWaylandOutput *>(workspace()->activeOutput());
|
||||
}
|
||||
const QPointF globalPos =
|
||||
devicePointToGlobalPosition(tte->transformedPosition(output->modeSize()),
|
||||
output);
|
||||
|
|
Loading…
Reference in a new issue