Commit graph

26589 commits

Author SHA1 Message Date
Xaver Hugl
4037f093db plugins/qpa: support recovering from GPU resets
When the context experienced a GPU reset, the context and all swapchains need
to be recreated or there will be glitches
2024-04-26 14:27:07 +00:00
Vlad Zahorodnii
e2611d710f plugins/screencast: Avoid resetting m_dmabufParams when resizing the stream
ScreenCastStream::onStreamAddBuffer() can be called before the stream
params are updated. This is problematic because that function expects a
valid m_dmabufParams.

The reason why m_dmabufParams is reset is to force the onStreamParamChanged()
function to check whether dmabufs can be still allocated with the new size.
2024-04-26 13:31:17 +00:00
Vlad Zahorodnii
31f80d18f2 wayland: Use xdg-dialog-v1 basename 2024-04-26 11:31:34 +00:00
David Redondo
2e92fca017 plugins/zoom: Center cursor on active screen on shortcut
BUG:435108
2024-04-26 10:41:49 +00:00
Vlad Zahorodnii
69b8c91655 Drop more (unnecessary) geometry updates blockers 2024-04-26 08:01:21 +00:00
Jakob Petsovits
351f613ef4 kcms/desktop: Expand button label from "Add" to "Add Desktop"
Also pull "Rows" out of the SpinBox into a dedicated label.

Both to address concerns "Add" about being misinterpreted as
"Add Row", given that the button to add a new virtual desktop
now sits right next to the row count spinner.
2024-04-26 00:00:11 -04:00
l10n daemon script
e804b45d86 GIT_SILENT Sync po/docbooks with svn 2024-04-26 01:21:46 +00:00
Xaver Hugl
4dffc09aaa input: fix warning about nodiscard
std::any_of is used here in a way it was never meant to be used...
Instead just write out the loop
2024-04-25 19:24:19 +02:00
Vlad Zahorodnii
4a70793e2b Apply 1 suggestion(s) to 1 file(s) 2024-04-25 11:59:52 +00:00
Vlad Zahorodnii
c404c76a8b plugins/screencast: Use steady clock to generate last sent timestamps
The steady clock is more preferred for generating timestamps because it
ensures that timestamps increase monotonically.

This fixes screencasts freezing in obs after changing the system time.
2024-04-25 14:52:30 +03:00
Vlad Zahorodnii
5ff705a124 plugins/screencast: Make frame throttling less strict
If the max framerate is 60Hz, currently, the frameInterval is going to
be 16.6ms. On the other hand, lastSentAgo is likely to be just 16ms. So
the frame throttling timer will be started just to wait less than a
millisecond.
2024-04-25 11:26:36 +00:00
Vlad Zahorodnii
24f4e268a9 plugins/screencast: Reset last sent timestamp when the stream resumes
Hypothetically, if the stream is paused and restarted in a short burst,
the frame throttling logic can be mis-triggered.
2024-04-25 11:16:59 +00:00
l10n daemon script
529ccbbd18 GIT_SILENT Sync po/docbooks with svn 2024-04-25 01:24:03 +00:00
Vlad Zahorodnii
068f1c2b54 Drop support for geometry updates blocking in wayland windows
Geometry updates are very asynchronous on wayland, the update blockers
should be redudant.
2024-04-24 14:39:09 +00:00
Vlad Zahorodnii
1470cfc790 Drop Window::keepInArea() overload with hidden moveResize()
Hidden moveResize() calls stand in the way of making geometry code
reusable or more refactorable. They also usually require one using
geometry update blockers, which are just a horrible concept because
they make geometry code unnecessarily more complex and add more failure
points.
2024-04-24 14:19:42 +00:00
Vlad Zahorodnii
bc29e09d88 plugins/screenshot: Fix monitor screenshots on x11
After some refactoring changes, m_paintedScreen is always the first
output on x11, so it's no longer possible to take screenshots of other
outputs.
2024-04-24 14:01:12 +00:00
l10n daemon script
98aa044508 GIT_SILENT Sync po/docbooks with svn 2024-04-24 01:35:03 +00:00
Xaver Hugl
7949032411 outputconfigurationstore: don't overwrite output settings with kscreen configs
The existing code overwrites all per-output data with the config from KScreen
every time an output config is found that isn't in the KWin data base yet.
That causes problems like the scale being reset to 1.0 if the user logged
into Xorg before, or resetting it to whatever scale KScreen had saved on
Wayland, which isn't much better.

Instead of doing that, use the KScreen config as inspiration for some specific
output settings, instead of copying it outright. It's not ideal, but it's
better than overwriting settings the user has explicitly set up

BUG: 485353
2024-04-23 11:41:40 +00:00
l10n daemon script
38694bbe1a GIT_SILENT Sync po/docbooks with svn 2024-04-23 01:34:47 +00:00
Xaver Hugl
c14c61f745 backends/drm: use dumb buffers for the cursor on virtual machines
Apparently not all VM drivers handle dmabufs on the cursor plane correctly

BUG: 485827
2024-04-22 12:33:42 +00:00
Vlad Zahorodnii
1f32171ac9 ci: Switch to suse_tumbleweed_qt67 2024-04-22 15:26:22 +03:00
l10n daemon script
1da8b61864 GIT_SILENT Sync po/docbooks with svn 2024-04-22 01:34:05 +00:00
Xaver Hugl
fba948b39f scene/workspacescene: don't check direct scanout candidates for a pixmap
We don't need a pixmap for direct scanout, and the drm backend destroys the pixmap
when direct scanout is successful... so this check created a loop of direct scanout
working and not working, and worse, the client reallocating its buffers each time.

BUG: 485639
BUG: 485730
BUG: 485712
CCBUG: 477016
2024-04-19 23:06:56 +02:00
Xaver Hugl
48197a4f5b backends: don't duplicate file descriptors as often
Instead, move them when possible
2024-04-19 19:32:43 +00:00
l10n daemon script
7bd6b92110 GIT_SILENT Sync po/docbooks with svn 2024-04-19 01:29:00 +00:00
Xaver Hugl
eed7943939 wayland/surface: fix the change signal for release points not being emitted 2024-04-17 13:59:43 +02:00
l10n daemon script
09b32a1e68 GIT_SILENT Sync po/docbooks with svn 2024-04-17 01:29:07 +00:00
Erik Kurzinger
9ca7b9b1cf core/syncobjtimeline: import release fence at correct timeline point
SyncTimeline::moveInto imports the provided fence to the syncobj by
calling drmSyncobjImportSyncFile. However, that function assumes the
syncobj a binary syncobj, meaning the fence will be imported at timeline
point 0, not at the intended timeline point.

Since there is no timeline equivalent of drmSyncobjImportSyncFile, to
achieve the correct behavior we create a temporary binary syncobj,
import the fence into that, and then use drmSyncobjTransfer to transfer
the fence to the desired timeline point on the destination syncobj.

Signed-off-by: Erik Kurzinger <ekurzinger@nvidia.com>
2024-04-16 14:45:48 -07:00
Xaver Hugl
26afbfb6fa wayland_server: guard against DRM_IOCTL_SYNCOBJ_EVENTFD being broken
...either because it's not implemented, or because it's buggy.
2024-04-16 13:51:42 +02:00
Fabian Vogt
01d224fa22 Fall back to breeze_cursors if neither configured nor default can be loaded
Try harder to get some cursor theme loaded, otherwise the cursor is
invisible, which also makes it hard to fix the configuration.

Also add some warnings instead of failing silently.
2024-04-16 11:50:48 +02:00
l10n daemon script
98747246cd GIT_SILENT Sync po/docbooks with svn 2024-04-16 01:31:06 +00:00
David Edmundson
3ed535dd67 Remove superfluous wake in dpmsinputeventfilter destruction
Workspace already makes sure to only dynamically delete the
dpmsinputeventfilter if all screens are currently on. This line to wake
all screens is therefore redundant.

It's problematic as it can cause a crash on final teardown when
workspace is destroyed.

BUG: 484861
2024-04-15 22:03:51 +00:00
David Redondo
bca99d0b4c Add missing license header
Amends 499d006e3a
GIT_SILENT
2024-04-15 16:13:00 +02:00
David Redondo
499d006e3a Add a libeis input backend plugin
This adds a libeis backend via plugin which supports clients sending
emulated input events. No public listening socket is exposed,
clients are expected to go through the RemoteDesktop portal.
In order to restrict the device types available to clients
according to what was approved via the portal a separate eis
context per portal request is created. The communication with
the portal happens through a simple dbus interface where cookies
are  handed out for each eis context so the portal can inform KWin
when the portal session is closed/should end.
2024-04-15 13:05:15 +00:00
David Redondo
2120e18729 Make InputRedirection::addInputBackend public
This allows plugins to register additional input backends.
2024-04-15 13:05:15 +00:00
David Redondo
9ba95ecd5d Export KeyboardLayout 2024-04-15 13:05:15 +00:00
Marco Martin
52b92904de Quick tiling double buffereing
The quicktileMode member now is just for the requested tile mode, base the "real" mode only on m_tile.

The requested tile mode is used for double buffering, to look and behave just like requestedMAximizeMode() which is updated immediately, but needs to acknowledge the configure request and render for quickTileMode() (and the right tile() instanced to be associated) to be updated accordingly
2024-04-15 12:18:09 +00:00
Xaver Hugl
36001e5ee0 increase minimum libdrm version to 2.4.116
It's required for drmSyncobjEventfd
2024-04-15 09:22:00 +00:00
Aleix Pol
1ab5453a90 EffectLoader: Warn about trying to load an invalid effect
If the metadata of the effect is invalid, loadEffect will complain
rather than failing silently, making debugging issues a bit harder and
it's something that we are already checking for and shouldn't
realistically be happening.
2024-04-15 00:47:33 +02:00
l10n daemon script
5e94f5429a GIT_SILENT Sync po/docbooks with svn 2024-04-14 01:22:41 +00:00
l10n daemon script
f7a36a43d9 GIT_SILENT Sync po/docbooks with svn 2024-04-13 01:28:05 +00:00
ivan tkachenko
344e56dd77
plugins/dialogparent: Disable darkening while picking colors
Integrate with colorpicker effect to disable window darkening while
color picker effect is active. Unfortunately, this solution has couple
of limitations:
- active state of effects is not an observable property, so a new
  property had to be added to the effects singleton;
- consequently, list of active effects is not an observable property, so
  the whole thing could not be implemented in pure QML in the dialog
  parent effects;
- actual isActive() state of the color picker for whatever reason
  required that m_scheduledPosition is not an invalid point,
  effectively making it always inactive except for a brief moment
  between addRepaintFull() call and paintScreen() callback. That check
  had to be removed.
- QColorDialog windows are still modal and darkened by default;
- QColorDialog on X11 does not use portals/KWin, so this trick does not
  apply at all;
- effects->isScreenLocked() which isActive() depends on is not an
  observable property either.

BUG: 172921
2024-04-12 22:39:01 +06:00
Nate Graham
99324c12fd plugins/overview: remove middle click to close virtual desktop
This is a hidden destructive action[1] in a context where users are not
primed to expect it. It's also largely unnecessary since the delegates
already show a delete button on hover, and deleting virtual desktops
isn't such a common task that it benefits from an accelerator. Let's
remove it for safety.

[1] It's destructive because user-created state on the deleted virtual
desktop is lost--with no confirmation or undo, to boot.

BUG: 484999
FIXED-IN: 6.1
2024-04-12 13:25:58 +00:00
Xaver Hugl
64e0b693c7 core/output: remove direct scanout inhibition
It's not used anywhere
2024-04-12 12:58:55 +00:00
Carl Schwan
b2f181fe80 Update kirigami target
Since kf6, FindKirigami2Config is deprecated in favor of
FindKirigamiConfig
2024-04-12 10:22:48 +00:00
l10n daemon script
89b6a67232 GIT_SILENT Sync po/docbooks with svn 2024-04-12 01:26:17 +00:00
Xaver Hugl
749b80ab49 backends/wayland: rename framePending to setPendingFrame
It's more clear about what the method does
2024-04-11 22:36:59 +00:00
Aleix Pol Gonzalez
881858f8dd Remove a number of unused forward declarations of gbm_* structs
Found this while debugging something else, seems like it's a good
cleanup.

Signed-off-by: Victoria Fischer <victoria.fischer@mbition.io>
2024-04-11 22:05:21 +00:00
Yifan Zhu
1a4606d990 scripting/windowmodel: match screen closest to center for filter
When filtering windows by screen, match the screen closest to the window
center, instead of testing whether the window is visible on the current
screen. The new method guarantees that when filtering by screen, the
window appears for exactly one screen. Previously windows spanning
multiple screens appear on all of them, and off-screen windows are not
shown in any screen.

BUG: 480028
BUG: 485337

FIXED-IN: 6.0.4
2024-04-11 09:36:26 -07:00
Vlad Zahorodnii
bf4c5241a0 backends/x11: Use correct allocator when using software rendering
The drm device will be null when using software rendering.
2024-04-11 16:36:46 +03:00