plugins/screencast: Avoid damaging full screen on rotated outputs
Not sure what that check is for, but things should work as expected even without it.
This commit is contained in:
parent
5368537981
commit
0ef12b69a1
1 changed files with 3 additions and 7 deletions
|
@ -130,14 +130,10 @@ void ScreencastManager::streamOutput(KWaylandServer::ScreencastStreamV1Interface
|
|||
auto stream = new ScreenCastStream(new OutputScreenCastSource(streamOutput), this);
|
||||
stream->setObjectName(streamOutput->name());
|
||||
stream->setCursorMode(mode, streamOutput->scale(), streamOutput->geometry());
|
||||
auto bufferToStream = [streamOutput, stream](const QRegion &damagedRegion) {
|
||||
if (damagedRegion.isEmpty()) {
|
||||
return;
|
||||
auto bufferToStream = [stream](const QRegion &damagedRegion) {
|
||||
if (!damagedRegion.isEmpty()) {
|
||||
stream->recordFrame(damagedRegion);
|
||||
}
|
||||
|
||||
const QRect frame({}, streamOutput->modeSize());
|
||||
const QRegion region = streamOutput->pixelSize() != streamOutput->modeSize() ? frame : damagedRegion;
|
||||
stream->recordFrame(region);
|
||||
};
|
||||
connect(stream, &ScreenCastStream::startStreaming, waylandStream, [streamOutput, stream, bufferToStream] {
|
||||
Compositor::self()->scene()->addRepaint(streamOutput->geometry());
|
||||
|
|
Loading…
Reference in a new issue