Commit graph

21117 commits

Author SHA1 Message Date
Xaver Hugl
6012e409a6 backends/drm: fix multi-gpu
The import code was added but not actually used
2022-03-16 16:32:08 +00:00
Xaver Hugl
36088cc82c backends/drm: fix crash in aboutToStartPainting
m_gbmSurface may still be nullptr
2022-03-16 16:32:08 +00:00
Xaver Hugl
0cd453690b backends/drm: split out layers for lease outputs and remove DrmDisplayDevice 2022-03-16 16:32:08 +00:00
Xaver Hugl
aac7f50d8b backends/drm: remove some unnecessary redirection 2022-03-16 16:32:08 +00:00
Xaver Hugl
0ba5916fe6 backends/drm: remove retry-logic for atomic commits
While it can make KWin work even when the driver changes properties
behind its back, it can also mask bugs in KWin.
2022-03-16 15:18:47 +00:00
Vlad Zahorodnii
b0982f7bbc wayland: Drop ptrace logic
kwin disables ptrace for a good reason - to prevent other processes from
attaching to kwin and snooping sensitive data or taking control of kwin.
But, that will also make things such as memory statistics unavailable to
read, etc.

On the other hand, the supported platforms where kwin runs all have
security measures in places to forbid shady processes ptrace'ing kwin.
For example, on Linux it's YAMA.

On Linux, by default, a process can ptrace only its descendants. For
example, this can be used by debuggers; otherwise you would need to be
the superuser to attach to any process.

This change drops our ptrace logic in favor of system provided security
measures. It allows the System Monitor to gather kwin's memory usage
statistics and also simplifies code, the current debugger detection
logic is not really robust.

If the system provided security measures are proven to be insufficient,
we can add the ptrace disabling logic back, but it would be great to
avoid that because system monitor won't be able to gather resource usage
statistics, which can be useful for detecting memory leaks in plasma
wayland session, etc.
2022-03-16 14:16:14 +00:00
Vlad Zahorodnii
79a4733dc5 autotests: Fix TestDbusInterface with KWIN_BUILD_ACTIVITIES=OFF 2022-03-16 12:36:18 +00:00
Kai Uwe Broulik
9f9e32e57d Remove unused Qt QuickWidgets dependency
Signed-off-by: Victoria Fischer <victoria.fischer@mbition.io>
2022-03-16 11:31:09 +00:00
Kai Uwe Broulik
39038afe8e gitlab-ci: Build decorations in minimal CI run
A lot of integration tests rely on the fact that there is a
window decoration.

The `KWIN_BUILD_DECORATIONS` pretty much only disables
build of Aurorae window decoration plug-in but otherwise
has no impact on KWin's core code base in terms of ifdefs
or dependencies required.

Re-enable building decorations to unbreak those tests.

Signed-off-by: Victoria Fischer <victoria.fischer@mbition.io>
2022-03-16 11:01:43 +01:00
Volker Krause
57e0119d23 Adapt to Qt6's removal of Qt::X11Extras 2022-03-16 06:45:42 +00:00
l10n daemon script
45abf173f9 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"
2022-03-16 01:44:25 +00:00
Aleix Pol
f0ce2a0f53 screencasting: Support regions from the v3 of the protocol 2022-03-15 19:49:54 +00:00
Volker Krause
2139e2abab Port away from deprecated QWheelEvent constructors
The additional arguments are based on what the deprecated ctors did
internally.
2022-03-15 18:46:10 +00:00
Michail Vourlakos
f5c4040ac1 [aurorae] remove deprecated blur metadata
- blur json metadata is not needed any more in favor of KDecoration2 blurRegion
2022-03-15 17:17:50 +00:00
Eric Edlund
934f50717e Move 4 finger swipe up to overview effect 2022-03-15 13:29:05 +00:00
Eric Edlund
7a6792aa2f Make desktop grid effect check for active effects before responding to gestures 2022-03-15 13:29:05 +00:00
Eric Edlund
5cf8db26ec Changes to GestureRecognizer and gestures 2022-03-15 13:29:05 +00:00
Michail Vourlakos
f8b1b7f47e [aurorae] fix incorrectly disabled blur for maximized windows
when aurorae decorated windows become maximized and back to normal, after a while they all start to disable blur for their decorated maximized windows.

- bug was tracked down to aurorae fault sending empty QRegions for its maximized windows. What probably happens is that because mask FrameSvgItem enabled borders change from AllBorders to NoBorder, mask FrameSvgItem calculations can not catch up
- the new approach is lighter than the previous one and simpler as margins and enabledborders for mask framesvgitem are not changed and in the c++ side no QRegions calculations are needed at all for maximized windows
- in my system with the new code changing from normal window to maximized one feels a bit snapper
2022-03-15 13:21:46 +00:00
Volker Krause
ad09d9cc1e Adapt to various Qt6 container changes
QHash::unite is gone, container sizes are no longer int, comparison
operators are enforced to be const.
2022-03-15 08:52:21 +00:00
Xaver Hugl
945a2059b8 egldmabuf: port modifiers to QVector
With this we don't have to convert back and forth between QVector and QSet
to access the data
2022-03-15 08:18:37 +00:00
Volker Krause
ef1e22f517 Adapt to Qt6 nativeEventFilter changes 2022-03-15 07:34:24 +00:00
l10n daemon script
c7b2c64967 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"
2022-03-15 01:43:59 +00:00
Volker Krause
5eb4c1722a Port from I18N_NOOP to KLazyLocalizedString 2022-03-14 20:16:35 +00:00
Volker Krause
a6b5eb3ebb Use non-deprecated QButtonGroup signal 2022-03-14 17:39:53 +00:00
Volker Krause
f6f2c28aa6 Add additional includes needed by Qt6 2022-03-14 16:41:10 +00:00
Volker Krause
7455507d07 Don't rely on implicit QWeakPointer casting
Needs to be explicit with Qt6.
2022-03-14 16:02:41 +00:00
Harald Sitter
fad658200f fix dependency lookup
the target is called ConfigCore, the relevant cmake config is not.
notably KF5ConfigConfig.cmake is the present file, so look for the
correct name, otherwise the dependency isn't found
2022-03-14 15:15:23 +00:00
Volker Krause
9d9e89fb84 Don't rely on implicit QScopedPointer to bool conversion
No longer available in Qt6.
2022-03-14 13:58:55 +00:00
Xaver Hugl
1fd1c03742 screencast: make context current in tryEnqueue
The method is used when the cursor position changes. There is no guarantee
that a context would be current at that point in time
2022-03-14 01:58:31 +00:00
l10n daemon script
9eecefd157 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"
2022-03-14 01:44:59 +00:00
Jack Hill
a7fdb9ad16 Add Accessibility keyword
This module has various settings for accessibility so it makes sense to have this as a keyword.
2022-03-13 23:22:55 +00:00
Volker Krause
a34717dc22 Ensure moc sees fully qualified property types
Qt6 insists on that. We can do this either by including the moc files,
or by including the corresponding headers in the header defining the
properties, the former seems cleaner when possible.
2022-03-13 16:56:26 +00:00
Volker Krause
eee16b01a4 Port away from deprecated QWheelEvent position methods
Those are gone in Qt6 (unlike similarly named methods for other
event types).
2022-03-13 12:23:22 +00:00
Volker Krause
51250cfb4a Use | rather than + for combining QFlags
The plus operator is no longer available for flags in Qt6.
2022-03-13 10:00:54 +00:00
l10n daemon script
03c80db56d 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"
2022-03-13 01:57:28 +00:00
Volker Krause
19538a8dcb Fully qualify Qt::endl, needed with Qt6 2022-03-12 17:04:44 +00:00
Volker Krause
7188f8fbd1 Port away from deprecated q[s]rand() methods 2022-03-12 12:58:07 +00:00
Volker Krause
c5a712a77a Don't rely on implicit conversion from int to QUuid
Not available in Qt6 anymore.
2022-03-12 10:48:44 +00:00
Volker Krause
f6d14f0401 Adapt to QQuickItem::geometryChanged() rename in Qt6 2022-03-12 09:57:32 +00:00
Volker Krause
fe56f36dd0 Port to QRecursiveMutex
Recursive and non-recursive mutexes are distinct types in Qt6.
2022-03-11 15:39:09 +00:00
Volker Krause
ce22e95d89 Adapt to QtConcurrent API changes in Qt6 2022-03-11 15:01:26 +00:00
Volker Krause
0143b63527 Use version-less Qt macros, targets and variables
Prepares for building against Qt6.
2022-03-11 14:37:24 +00:00
Michail Vourlakos
a1fec92ef2 [blur] use blurRegion to identify if a decoration supports blur
Having blurRegion to identify if a decoration supports blur or not instead of the metadata-json way has the following benefits:

- decorations can now provide both blur or not based on user preference
- theme engines such as Aurorae do not have to enforce blur or not to their themes and they can support blur enabled and disabled themes at the same time if they want to
- blurRegion is empty by default so the Korners bug will be fixed for all solid aurorae themes. Breeze and Oxygen have set **blur:false** so nothing changes for them.
- all aurorae themes that do not require blur will free up system resources by default
2022-03-11 13:13:38 +00:00
Arjen Hiemstra
bd920fb28c effects: Guard against InputMethod being nullptr or not enabled
Apparently InputMethod can be nullptr, in which case we end up
dereferencing nullptr when we try to get the input panel.
2022-03-11 10:16:30 +01:00
Nate Graham
44184f4700 effects/overview: add subtle outline around non-active desktops
Otherwise they have no border and look kind of cut off.

BUG: 450739
FIXED-IN: 5.25
2022-03-10 15:14:13 -07:00
Volker Krause
cd74345652 Adapt to QQmlListProperty API changes in Qt6 2022-03-10 20:48:26 +00:00
Arjen Hiemstra
9253c06105 Disable animations for Maliit when launching it as input method
Maliit does client side animation by default but can be told to disable
them using an environment variable. Since we now want to do this
animation in KWin, always disable the client side animations in Maliit.

It feels slightly weird to unconditionally add a Maliit-specific
variable, but at the same time all other solutions are more error prone
and would likely need more code.
2022-03-10 18:41:22 +00:00
Arjen Hiemstra
844c451156 slidingpopups: Support animating show/hide of input method panel
This adds support for animating showing/hiding of the input method panel
to the sliding popup effect, if the input panel is of type "Toplevel".

This is mainly intended to animate showing the virtual keyboard and has
been primarily tested with Maliit. It replaces the client-side animation
that Maliit would do, instead doing the animation on the KWin side which
provides a significantly smoother experience.
2022-03-10 18:41:22 +00:00
Volker Krause
13f28d7d6d Port away from QList::toSet
That's gone in Qt6, replaced by range constructors.
2022-03-10 17:13:38 +00:00
Volker Krause
205fd169e5 Port from KNS3::Button to KNSWidgets::Button
The former isn't available in KF6 anymore.
2022-03-09 18:13:27 +01:00