Commit graph

26781 commits

Author SHA1 Message Date
Niccolò Venerandi
a56b16e2ff Remove orphan shortcuts for desktop grid and expose effects
BUG:487974
2024-06-04 10:09:08 +00:00
Vlad Zahorodnii
eea79bddd8 backends/libinput: Destroy Connection in correct thread 2024-06-04 10:00:17 +00:00
Vlad Zahorodnii
7622921de6 Explicitly destroy WaylandServer in ApplicationWayland destructor
Otherwise the WaylandServer will be destroyed when QCoreAppplication is
gone, which is too late.
2024-06-04 10:00:17 +00:00
Vlad Zahorodnii
b4822389c3 Create WaylandServer after backends
Move WaylandServer after backends so it's less tempting to use WaylandServer
in low level components.
2024-06-04 10:00:17 +00:00
David Edmundson
8c149bb6b7 effects: Do not call RHI QQuickRenderControl methods when using software rendering
As per the docs:
Note: This function does not need to be, and must not be, called when
using the software adaptation of Qt Quick.

This sets up RHI on the render control, which in turn sets RHI on the
window, which shouldn't exist when using software rendering.

BUG: 482663
BUG: 486078
2024-06-04 08:33:19 +00:00
l10n daemon script
fd746b46e5 GIT_SILENT Sync po/docbooks with svn 2024-06-04 01:24:29 +00:00
Vlad Zahorodnii
cadf16b12e Improve handling of closed windows
A layer shell window can request a screen edge without having a chance
to map the surface. In that case, no Workspace::windowRemoved() signal
is not going to be emitted because no surface has been mapped. Perhaps
it needs some re-wiring, but on the other hand, it is also more reasonable
to monitor Window::closed() signal.

With this change, the ScreenEdges manager will reject any request to
reserve a screen edge for a closed window. And in addition to that,
the ScreenEdges will unreserve screen edges when the window is closed
rather than when the window is unmapped.

CCBUG: 485318
2024-06-03 14:54:40 +00:00
Vlad Zahorodnii
01a9eb2327 plugins/screencast: Stop frame rate throttling timer when stream is paused
Hypothetically, m_pendingFrame can be armed when the stream is paused.
It is undesired to call recordFrame() in that case.
2024-06-03 12:54:39 +00:00
Vlad Zahorodnii
d048f9aad8 autotests: Destroy WaylandServer before Application 2024-06-03 11:22:13 +00:00
Vlad Zahorodnii
79238b06cf core: Check that GraphicsBuffer references change on the main thread 2024-06-03 11:22:13 +00:00
David Edmundson
79ef1be57b xwayland: Avoid crash if processing keys after xwayland is disconnected
Whilst the XWayland input filter only runs whilst XWayland is running
there is hypothetical window between the wayland connection to xwayland
being disconnected and handleXwaylandFinished, the process exiting. This
should be guarded correctly.

BUG: 480925
2024-06-03 10:23:57 +00:00
Vlad Zahorodnii
8b843e647c xwayland: Initiate x-to-wayland dnd only if the seat permits it
This is mainly to avoid creating lingering m_currentDrag object if
SeatInterface::startDrag() refuses to start a dnd session.
2024-06-03 09:54:32 +00:00
Vlad Zahorodnii
ee4cf67371 wayland: Refuse starting dnd if there's another dnd session in progress
If a new drag and drop session is started while there is already one
existing, it's possible to end up in a situation where the
SeatInterface::dragEnded signal is emitted the second time when one of
the data sources is destroyed.

CCBUG: 460374
2024-06-03 09:54:32 +00:00
David Edmundson
1c3a987d74 wayland: Only load HiddenPreviews options in X11
HiddenPreviews was a hack to not inform X11 that windows were minimised,
so that their previews kept working.

On wayland the user facing setting is not visible but the value is
loaded which is a bad combination.

CCBUG: 415286
2024-06-03 08:36:53 +00:00
Aleix Pol Gonzalez
26d9361695 core,backends/drm: Improve error logging
Write something into the logs when a call goes awry, it can save some
time to the next person porting kwin to a dysfunctional driver.

Signed-off-by: Victoria Fischer <victoria.fischer@mbition.io>
2024-06-03 08:14:32 +00:00
Sam James
31a3961c4c
watchdog: add includes for geteuid
05a3e2bad9 added `geteuid` use but didn't
add the needed headers. This works by chance on libstdc++ systems via
transitive includes, but it doesn't work on libc++ systems, as reported
downstream in Gentoo at https://bugs.gentoo.org/933120.
2024-06-02 00:25:26 +01:00
l10n daemon script
a1f30edaf6 GIT_SILENT Sync po/docbooks with svn 2024-06-01 01:25:57 +00:00
l10n daemon script
e84ca82c9a SVN_SILENT made messages (.desktop file) - always resolve ours
In case of conflict in i18n, keep the version of the branch "ours"
To resolve a particular conflict, "git checkout --ours path/to/file.desktop"
2024-06-01 01:18:54 +00:00
David Edmundson
f700de56f8 core: Disable Qt RHI pipeline cache
The Qt pipeline cache causes a disk sync on every load and save of a
QQuickWindow. This causes a stutter under high disk usage.

The gains from this cache are minimal on our simple scenes on PC
hardware. Especially given mesa has it's own cache, profiling on my
personal laptop showed the pipeline as being 0ms.

There is an upstream patch at
https://codereview.qt-project.org/c/qt/qtdeclarative/+/564411 .
QSaveFile still has a sync, but that should only be hit for the first
non-cached run. I'm also adding a flag to QSaveFile to fix the QML cache
and first run case. 

Tested via running kwin with `strace -e
inject=fdatasync:delay_enter=10000000` to simulate a slow flush.

BUG: 487043
2024-05-31 15:28:09 +00:00
Vlad Zahorodnii
40839e3347 plugins/startupfeedback: Don't show bouncing cursor if cursor is invisible
BUG: 482566
2024-05-31 15:00:10 +00:00
Vlad Zahorodnii
2ca81bbe32 kcms/decoration: Use "grab" and "grabbing" cursor to communicate dnd state 2024-05-31 14:24:51 +00:00
Vlad Zahorodnii
d7772031b1 Use "grabbing" cursor during interactive move
BUG: 483305
2024-05-31 14:24:51 +00:00
Xaver Hugl
1195936a68 opengl/openglcontext: correct the check for glMapBufferRange support
It's also supported with OpenGL ES 3.0
2024-05-31 12:11:39 +00:00
Xaver Hugl
f4f0660dbb opengl/openglcontext: correct the check for buffer storage support
BUG: 487777
2024-05-31 12:11:39 +00:00
l10n daemon script
4ab679f2fd GIT_SILENT Sync po/docbooks with svn 2024-05-31 01:37:59 +00:00
David Edmundson
5d90f232bd effects: Disable showing desktop when starting any fullscreen effect
Fullscreen effects typically will show all the windows, when the effect
ends having the windows disappear doesn't really work.
From a user point of view any full screen effect is a new task, we want
to cancel any preivous task.

BUG: 487299
2024-05-30 08:06:56 +00:00
l10n daemon script
0ce7a40850 GIT_SILENT Sync po/docbooks with svn 2024-05-30 01:30:05 +00:00
Xaver Hugl
2cf36e640f core/renderloop: honor repaint scheduling requests from effects with vrr
Until effects are converted to schedule repaints on the item they're modifying,
we need to allow repaint scheduling from nullptr items, and handle repaints on
the (cursor) render layers to still be filtered out

BUG: 487480
2024-05-29 12:46:26 +00:00
David Redondo
cefcdf7db5 Unset suspended state of windows that are marked for offscreen rendering
Otherwise some clients will not render anything even though we are
sending frame callbacks.
BUG:487702
FIXED-IN:6.1
2024-05-29 12:02:01 +00:00
Vlad Zahorodnii
64ddeff3bd Forbid activating override redirect windows
BUG: 486026
2024-05-29 10:51:23 +00:00
Łukasz Patron
ce57af62ec scripting: Filter out windows with isClient=false in WindowModel
These windows render as empty boxes and opening them crashes the KWin.
Also, the same check is present in TabBox.

BUG: 486182
2024-05-29 10:45:14 +00:00
David Redondo
ba7b23c41d autotests/test_xkb: Do not expect fail in fixed Qt versions 2024-05-29 12:12:42 +02:00
l10n daemon script
59f1f7ee9f GIT_SILENT Sync po/docbooks with svn 2024-05-29 01:44:10 +00:00
l10n daemon script
c164ff467c SVN_SILENT made messages (.desktop file) - always resolve ours
In case of conflict in i18n, keep the version of the branch "ours"
To resolve a particular conflict, "git checkout --ours path/to/file.desktop"
2024-05-29 01:17:54 +00:00
David Redondo
ec1ebb6fb8 Use di_info_get_serial to fetch the serial number from EDID
This will also look at the "product serial string" in addition
to the actual serial number. The former is what we use elsewhere
in Plasma like the kscreen kcm.
BUG:485015
FIXED-IN:6.1
2024-05-28 13:19:59 +00:00
Vlad Zahorodnii
1d05f98e4b qpa: Guard against failing to get a swapchain in platform opengl context
QOpenGLContextPrivate::setCurrentContext() was dropped because the
platform opengl context no longer uses QOpenGLFramebufferObject, which
needed QOpenGLContext::currentContext().
2024-05-28 12:51:10 +00:00
l10n daemon script
6a59c4defc GIT_SILENT Sync po/docbooks with svn 2024-05-28 01:26:54 +00:00
Xaver Hugl
804ecb0e22 core/renderloop: make repaint scheduling more robust against wrong render time estimations
When the render time estimation is much higher than the real render time, and triple buffering is
enabled, the previous logic would schedule frames multiple vblanks in advance, which could drop the
effective refresh rate by more than is necessary. This commit limits it to the second vblank after
the current time, which ensures that we hit the full refresh rate even when render time prediction
is wrong
2024-05-28 01:23:11 +02:00
Xaver Hugl
97c1d335e5 backends/drm: delay atomic commits until the time they're meant for
Otherwise, if render time prediction and actual render time are very different,
a lot of frames get dropped and in some cases more frames than is useful are
rendered, creating stutter instead of only unnecessary latency

BUG: 487605
2024-05-28 01:23:11 +02:00
Yifan Zhu
09d4f3fda3 xkb: support converting Qt keys to keysyms
QXkbCommon::toKeysym doesn't correctly handle the case where a single Qt
key map to multiple keysyms.

BUG: 482847
2024-05-27 18:27:33 +00:00
Vlad Zahorodnii
b0ccacc983 Avoid using QMouseEvent in processDecorationButtonPress()
BUG: 480864
2024-05-27 17:32:14 +00:00
Vlad Zahorodnii
fa351403ef Ignore button release events when double clicking
One could check that the double click timer is still active.
2024-05-27 17:32:14 +00:00
Vlad Zahorodnii
a76ae07ee1 Revert "effects: Use unique device for replaying events to QQuickView"
It broke overview.

This reverts commit 862dae455a.
2024-05-27 17:32:14 +00:00
Vlad Zahorodnii
447994581b xwayland: Fix dnd position with hidpi 2024-05-27 16:21:01 +00:00
Xaver Hugl
5e122cb6c0 wayland/linuxdrmsyncobjv1: don't emit a protocol error for unmapping a surface 2024-05-27 15:14:27 +02:00
Alois Wohlschlager
ae376766ef window: consistently use normal keyboard modifiers for tiling
A bad rebase in commit 43e5f17547 inadvertedly
reverted half of the fix from 1f1c54ca6c. As a
result, custom tiling would appear broken again for keyboard layouts where caps
lock is achieved by pressing both shift keys at the same time. Reapply the half
of the fix that went missing.
2024-05-27 09:56:31 +00:00
David Edmundson
862dae455a effects: Use unique device for replaying events to QQuickView
When a new mouse event is made it updates the global position of that
device. This causes issues if a mouse event is forwarded with an
adjusted position then used afterwards.

`QPointingDevice::primaryPointingDevice` creates a new pointer device
internally if the seat name does not exist. It is then shared between
future usages.

BUG: 480864
2024-05-27 08:55:27 +00:00
l10n daemon script
d0e07ba3e8 GIT_SILENT Sync po/docbooks with svn 2024-05-27 01:29:46 +00:00
l10n daemon script
669e90325c GIT_SILENT Sync po/docbooks with svn 2024-05-26 01:26:01 +00:00
l10n daemon script
9e3db94718 GIT_SILENT Sync po/docbooks with svn 2024-05-25 01:29:28 +00:00