Commit graph

24818 commits

Author SHA1 Message Date
l10n daemon script
182fcb1791 GIT_SILENT Sync po/docbooks with svn 2023-04-27 02:32:10 +00:00
Vlad Zahorodnii
00d404335e ci: Pass --repeat until-pass to ctest
Pass --repeat until-pass to make CI more robust to tests that randomly
fail.
2023-04-26 15:50:47 +03:00
l10n daemon script
34b651e526 GIT_SILENT Sync po/docbooks with svn 2023-04-26 02:34:56 +00:00
Vlad Zahorodnii
c2c229fb05 effects/screenshot: Fix potentially leaking screenshot fds to child processes
dup() doesn't copy flags such as FD_CLOEXEC.
2023-04-25 06:53:10 +00:00
Vlad Zahorodnii
60dc812b21 utils: Fix FileDescriptor duplicates potentially leaking to child processes
dup() doesn't duplicate flags such as FD_CLOEXEC.
2023-04-25 06:07:22 +00:00
l10n daemon script
8b4a0c35cc GIT_SILENT Sync po/docbooks with svn 2023-04-25 02:47:34 +00:00
Vlad Zahorodnii
5fb5f1c92b autotests: Stabilize testWaylandSeat
TestWaylandSeat::sync() ensures that events and requests can't be
reordered after it. That is, it guarantees that

- events sent from the compositor will be processed by the client
  before sync() finishes
- requests issued by the client will be processed by the compositor
  before sync() finishes

WaylandSyncPoint relies on the fact that wl_display_sync()'s callback
and other wayland events will be processed in the same event queue.

But, it's not the case right now. The wl_callback belongs to the default
event queue and KWayland::Client::Seat belongs to a different queue.

If the default event queue is dispatched first, the WaylandSyncPoint may
emit the done signal too early.

In order to fix sync(), this change ensures that WaylandSyncPoint's
wl_callback uses the correct event queue.
2023-04-24 11:40:24 +00:00
Nicolas Fella
2f1744b67b Disable quitLock
Otherwise a KJob finishing terminates the app
2023-04-24 10:49:15 +00:00
Vlad Zahorodnii
5a42d0ac0e autotests: Drop testDontCrashNoBorder
The test used to verify that kwin doesn't crash when ShellClient sets
new geometry. ShellClient used to access decoration borders without
checking whether decoration() is null.

On the other hand, we've added a bunch of new test cases in
testXdgShellWindow, so let's remove this one. If the bug is back, that
test will fail.
2023-04-24 10:13:58 +00:00
Vlad Zahorodnii
e9feaefa4b Handling failing to export GEM handle to prime fd
If gbm_bo_get_fd_for_plane() or gbm_bo_get_fd() fails, ensure that the
gbm buffer allocator properly handles it and doesn't return a
GraphicsBuffer object.
2023-04-24 11:08:04 +03:00
l10n daemon script
f4b20c00a5 GIT_SILENT Sync po/docbooks with svn 2023-04-24 03:00:58 +00:00
Vlad Zahorodnii
a89573224c Drop Qt6WaylandClientMacros.cmake fork 2023-04-23 18:18:34 +00:00
Xaver Hugl
e7c803b7e5 backends/drm: store drm properties directly in drm objects
This makes it possible to ensure type safety for enums, as each drm property
object can have its own type now, and it reduces the amount of typing needed
to access properties
2023-04-23 14:09:29 +02:00
Xaver Hugl
adc5104e2a autotests/drm: disable tests to work around FreeBSD CI issues
The tests don't do anything platform specific, so test only on Linux
until the cause of the problems is found
2023-04-23 14:09:29 +02:00
Xaver Hugl
2c86866876 backends/drm: drop some unused logging
We're using drm_info to get property values from users. If property logging
in KWin is needed, it will be different from what we had until now
2023-04-23 14:09:29 +02:00
Nicolas Fella
8a0a91fea1 Port to standalone kglobalacceld 2023-04-23 10:06:28 +02:00
l10n daemon script
6a54f76dc4 GIT_SILENT Sync po/docbooks with svn 2023-04-23 03:55:52 +00:00
Vlad Zahorodnii
111e98d24a autotests: Remove render node check in testPointerInput
The test doesn't require OpenGL anymore.
2023-04-22 20:28:59 +03:00
Vlad Zahorodnii
e3bc9e8ac6 autotests: Allow running lockscreen test with software rendering
The test needs OpenGL in order to ensure that the window view effect is
loaded and it registers a screen edge. On the other hand, we could
register a screen edge ourselves and thus allow running the test on
freebsd.
2023-04-22 16:45:40 +00:00
Vlad Zahorodnii
35efeddb48 wayland: Fix sending org_kde_plasma_virtual_desktop.removed
If a virtual desktop is removed, the client will receive two removed
events.
2023-04-22 15:45:25 +00:00
Vlad Zahorodnii
ac74de22c7 autotests: Fix testPlasmaVirtualDesktop
The test fails because it incorrectly handles the server-side and the
client-side virtual desktops being removed within one event loop cycle.

In order to fix the test, this change makes the removal of server-side
virtual desktop object take effect immediately.
2023-04-22 15:45:25 +00:00
Vlad Zahorodnii
959bb661af autotests: Drop testBufferSizeChange
testXdgShellWindow already tests intricate subsurface size changes. The
surface pixmaps are handled differently now too, so the test is not
useful as it used to be 4 or 5 years ago.
2023-04-22 15:03:19 +00:00
Vlad Zahorodnii
c54a324e99 autotests: Make PointerInputTest::testUnfocusedModifiers() less flaky
While 50ms is enough on dev machines, CI runners can be more loaded and
some events can arrive after more time.
2023-04-22 15:01:20 +00:00
Vlad Zahorodnii
e0da725533 autotests: Fix Test::waitForWindowDestroyed
Before Deleted merge, it used to be equivalent to waiting until the
window is closed.

This fixes tests waiting until the window closing animation completes
and the Window object is destroyed.
2023-04-22 13:55:29 +00:00
Vlad Zahorodnii
9852748a84 autotests: Use software rendering in testPointerInput
testPointerInput requires OpenGL compositing because it wants to test
cursor push back in the window view effect and the window view effect is
available only if OpenGL is supported.

On the other hand, ScreenEdgesTest::testPushBack() already tests similar
scenario, so let's drop relevant test in testPointerInput to allow
running it when using software rendering.
2023-04-22 13:10:11 +00:00
Vlad Zahorodnii
c693450976 backends/virtual: Port to gbm
The virtual backend uses the surfaceless platform. On the other hand, we
move in a direction where the graphics buffer type is explicit, which
creates issues for the virtual backend.

This change ports the virtual backend to gbm so we could manually
allocate dmabuf buffers in order to unify buffer handling in kwin.

Its main drawback is that you won't be able to use the virtual backend
on setups without render nodes. On the other hand, given that the
compositor is meaningless without clients being able to share buffers
with it, it's reasonable to require some way to create and export prime
buffers.
2023-04-22 15:09:59 +03:00
Vlad Zahorodnii
15f6c910be autotests: Fix crash
If a test case is skipped, there will be no input devices.
2023-04-22 09:15:24 +00:00
Vlad Zahorodnii
7a1a1161cc ci: Bump to Qt 6.5 2023-04-22 08:11:15 +00:00
l10n daemon script
cf3ab7a0ab GIT_SILENT Sync po/docbooks with svn 2023-04-22 02:53:00 +00:00
Vlad Zahorodnii
0e676ceb93 autotests: Reduce execution time of testWaylandSeat
Currently the test spends a lot of time idling. This change speeds up
the test by removing QTest::qWait() calls.

The sync() helper was introduced to sync both client and server sides.
It lets us simplify some code and get rid of QTest::qWait()s.

With this change, the execution time will drop from 20s to about 300ms.
2023-04-21 19:33:23 +00:00
Markus Ebner
d86da339d1 plugins/screencast: Provide absolute timestamps
Pipewire's buffer meta structure apparently wants the presentation timestamp
to be absolute (where absolute means number of nanoseconds since computer was started).
So subtracting the timestamp of the buffer breaks the timestamps later on in the pipeline.
2023-04-21 21:43:51 +03:00
Xaver Hugl
9e3999dc5f backends/drm: remove support for transforming the scene with hardware rotation
This feature is no longer needed, as the scene can efficiently do its own
transformations now. Support for using hardware rotation to make direct scanout
work specifically can be added again later
2023-04-21 19:46:29 +02:00
Xaver Hugl
8ca38fb328 backends/drm: fix buffer orientation check for direct scanout
Without hardware rotation, the buffer transform with always be "normal",
so all "normal" client buffers would be accepted for direct scanout, which
is not correct.

CCBUG: 467138
2023-04-21 15:35:11 +00:00
Alexander Lohnau
3ff7a527e3 kcms: Port to org.kde.config QML module from KConfig
The implementation in KDeclarative will be removed
2023-04-21 16:30:30 +02:00
Vlad Zahorodnii
ee31581006 autotests: Remove WAYLAND_ONLY tests
WAYLAND_ONLY will create two tests: one with Xwayland, the other without
Xwayland. This is somewhat wasteful and it results in higher CI times.

On the other hand, Xwayland is started on demand. If a test doesn't need
Xwayland, it won't start.

So let's remove WAYLAND_ONLY in order to lighten kwin on CI resources.
If wayland only tests are needed, we can consider passing the operation
mode to the WAYLANDTEST_MAIN helper, but there aren't such tests afaik.
2023-04-21 14:25:23 +03:00
Vlad Zahorodnii
67b898b803 Move DmaBufAttributes struct to GraphicsBuffer header
The main motivation is to avoid scattering graphics buffer things around
kwin.

DmaBufParams struct has been moved to the OutputBackend, but with the
introduction of buffer allocators, we need to port screencasting code to
the new abstractions some time in the future.
2023-04-21 06:38:58 +00:00
l10n daemon script
22b10c4055 GIT_SILENT Sync po/docbooks with svn 2023-04-21 02:37:10 +00:00
l10n daemon script
6f16d9b273 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"
2023-04-21 02:32:52 +00:00
l10n daemon script
60b3f492d9 GIT_SILENT Sync po/docbooks with svn 2023-04-20 02:47:31 +00:00
Xaver Hugl
9915cfc6df wayland: send modifiers to clients under the mouse 2023-04-19 14:19:52 +02:00
Xaver Hugl
ca9eb3d87d wayland/autotests/client: don't assume pointer enter and leave only increment serial by one 2023-04-19 14:19:30 +02:00
Vlad Zahorodnii
232bcc5d82 wayland: Drop support for linux dmabuf buffer flags
A client can specify the following flags when creating a linux dmabuf
client buffer:

- y_invert
- interlaced
- bottom_first

Only the y_invert flag is supported by kwin. The interlaced and the
bottom_first flags are ignored. On the other hand, most clients don't
specify the dmabuf flags. For example, neither EGL nor Vulkan WSIs
use the y_invert flag.

The y_invert flag is undesired because it also blocks optimizations such
as direct scanout because DRM assumes that the origin is in the top left
corner.

Therefore, this change drops the support for linux dmabuf flags. From
the protocol perspective, this is fine. It can be viewed as buffer
import failing with the specified flags.
2023-04-19 12:29:33 +03:00
Vlad Zahorodnii
99af2aa726 core: Move DmaBufAttributes getter to GraphicsBuffer
LinuxDmaBufV1ClientBuffer contains properties (formats, and flags) that
are not available in the base GraphicsBuffer type and there's no reason
to move it there.

In order to get rid of those properties (and eventually hide the
LinuxDmaBufV1ClientBuffer type from the public api), this change adds a
DmaBufAttributes getter in the GraphicsBuffer.
2023-04-19 07:29:38 +00:00
Vlad Zahorodnii
27b27696e8 {effects,scripts,plugins}: Use kwin translation domain
It makes it easier to handle translations when the plugins are stored in
the same directory.
2023-04-19 07:10:14 +00:00
Vlad Zahorodnii
64dca07d48 Remove Messages.sh in libkwineffects
It's unused.
2023-04-19 07:10:14 +00:00
Vlad Zahorodnii
e82e9b9f30 Move genericscriptedconfig to kcms directory
The kcms tree suits genericscriptedconfig better as the scripting
directory primarily contains the scripting api.
2023-04-19 07:10:14 +00:00
l10n daemon script
da13fe9c08 GIT_SILENT Sync po/docbooks with svn 2023-04-19 02:42:34 +00:00
Vlad Zahorodnii
07f6713a18 scene: Add pixel grid snapping debug pass
The debug shader is targeted to help with debugging blurriness when
using fractional scaling.

The shader works as follows:

- if the vertex coordinate has fractional part, the item will be
  highlighted with blue color
- if the texture coordinate (in device pixels) has fractional part,
  the item will be highlighted with red color

The shader can be toggled by setting the KWIN_SCENE_VISUALIZE=fractional
environment variable.
2023-04-18 08:16:11 +00:00
Hongfei Shang
6f5aa9e4f3 x11: only managed window need readTransient
X11Window::readTransient should not call setTransient for override-redirect windows.

Signed-off-by: Hongfei Shang <shanghongfei@kylinos.cn>
2023-04-18 06:43:26 +00:00
l10n daemon script
cfe656e506 GIT_SILENT Sync po/docbooks with svn 2023-04-18 02:34:50 +00:00