Summary:
This change extends the XInputEventFilter to also listen for all touch
events on the root window.
The touch points are passed to the new gesture recognizer in screenedges.
Please note that I'm not using X11 and have hardly tested this change in
real world. To our X11 users with touch screen support: please test!
Test Plan: Can activate and deactivate the screenedge.
Reviewers: #plasma, #kwin
Subscribers: plasma-devel
Tags: #plasma
Differential Revision: https://phabricator.kde.org/D5137
Summary:
Each Edge creates a SwipeGesture for touch activation. The swipe needs to
be a single finger starting from the edge into the screen for at least
20 %. The SwipeGesture and GestureRecognizer is extended to support the
use cases of the touch screen edge swipe.
New features supported by the gesture system are:
* minimum and maximum position
* a minimum delta for the swipe
* progress signal based on the minimum delta
* starting a swipe with a start point
The Edge has the progress signal connected to its approach signal, thus
visual feedback is provided through the screen edge effect.
The screen edge system supports touch only for the edges (corners are
too difficult to activate on touch screens). At the moment the following
features are supported:
* screen edge show/raise of windows (e.g. auto hidden panels)
* trigger the configured action
* trigger the configured callback function (e.g. script)
In future it might make sense to add a touch specific configuration
action to support different actions for screen edges activated by mouse
and touch.
BUG: 370323
Test Plan:
configured a screen edge and triggered through touch,
added an auto-hiding panel and triggered through touch
Reviewers: #kwin, #plasma_on_wayland
Subscribers: plasma-devel
Tags: #plasma_on_wayland
Differential Revision: https://phabricator.kde.org/D5106
Summary:
This change adds global touchpad swipe gestures to the
GlobalShortcutsManager and hooks up the swipe gestures as defined at the
Plasma Affenfels sprint:
* swipe up: Desktop Grid
* swipe down: Present Windows
* swipe left: previous virtual desktop
* swipe right: next virtual desktop
The main work is handled by two new classes: SwipeGesture and
GestureRecognizer. This is implemented in a way that it can be extended
to also recognize touch screen gestures and pinch gestures.
The SwipeGesture defines what is required for the gesture to trigger.
Currently this includes the minimum and maximum number of fingers
participating in the gesture and the direction. The gesture gets
registered in the GestureRecognizer.
The events for the gesture are fed into the GestureRecognizer. It
evaluates which gestures could trigger and tracks them for every update
of the gesture. In the process of the gesture tracking the
GestureRecognizer emits signals on the Gesture:
* started: when the Gesture gets considered for a sequence
* cancelled: the Gesture no longer matches the sequence
* triggered: the sequence ended and the Gesture still matches
The remaining changes are related to hook up the existing shortcut
framework with the new touchpad gestures. The GlobalShortcutManager
gained support for it, InputRedirection and EffectsHandler offer methods
to register a QAction. VirtualDesktopManager, PresentWindows and
DesktopGrid are adjusted to support the gesture.
Reviewers: #kwin, #plasma_on_wayland
Subscribers: plasma-devel
Tags: #plasma_on_wayland
Differential Revision: https://phabricator.kde.org/D5097
Summary:
Consider the following situation: we have three InputEventFilter linked
in the sequence A - B - C.
The input filters are processing pointer motion events. The expected
behavior is that the new motion is processed in the sequence
A -> B -> C
So far this did not work correctly if the pointer gets warped during the
processing. If e.g. filter B warps the pointer we get a motion sequence:
A (1) -> B (1) -> A (2) -> B (2) -> C (2) -> C (1)
The filters following the one warping the pointer get first the newer
than the older position. This is obviously wrong. Unfortunately it is not
just a theoretical condition, but a condition happening when interacting
with the screenedges, which warp the pointer.
This change introduces a PositionUpdateBlocker in
PointerInputRedirection::processMotion to ensure that a processMotion
call finishes prior to the next update. If the PositionUpdateBlocker is
blocked the new position gets scheduled and processed once the
PositionUpdateBlocker gets destroyed.
With this we get the expected sequence for B warping pointer:
A (1) -> B (1) -> C (1) -> A (2) -> B (2) -> C (2)
This should hopefully improve the interaction with screen edges on
Wayland.
CCBUG: 374867
Test Plan:
Added an auto test demonstrating the issue of incorrect
ordering caused by screenedges. Prior to the change the test is failing.
Reviewers: #kwin, #plasma
Subscribers: plasma-devel, kwin
Tags: #kwin
Differential Revision: https://phabricator.kde.org/D5182
Summary:
Currently, if user tries to move one of buttons to the left, ending up
dragging one button onto another, crash occurs.
In addition, this patch replaces verbose replacement(remove/insert) with
more elegant QVector<T>::move(int, int)
BUG: 374153
FIXED-IN: 5.8.7
Reviewers: graesslin, #kwin
Reviewed By: graesslin, #kwin
Subscribers: kwin
Tags: #kwin
Differential Revision: https://phabricator.kde.org/D5117
This makes clicking the application menu button trigger the menu.
CHANGELOG: Aurorae window decorations now support global menu button
BUG: 375862
FIXED-IN: 5.9.5
Differential Revision: https://phabricator.kde.org/D5130
Summary:
aurorae themes have hardoded sizes in pixels in their config files,
but the framesvgs scale by themselves based on font dpi leading
to corrupt results
scale all sizes using the same logic(that's also used in c++ based
kdecorations), gives correct looking scaled decorations
BUG:375868
Test Plan: see screenshot
Reviewers: #plasma, graesslin
Reviewed By: #plasma, graesslin
Subscribers: plasma-devel, kwin, #kwin
Tags: #kwin
Differential Revision: https://phabricator.kde.org/D5114
same as https://phabricator.kde.org/D5083,
gcc 4.8.5 (opensuse leap) fails building modeltest with
CMakeFiles/testHistoryModel.dir/modeltest.cpp.o: In function `ModelTest::data()':
modeltest.cpp:(.text+0x5a57): undefined reference to `bool QTest::qCompare<int, unsigned int>(int const&, unsigned int const&, char const*, char const*, char const*, int)'
Summary:
In the current code we update the shadows during the decoration paint.
Because this is called in the middle of the Scene::paintWindow and we
have already painted the shadows/built quads, the setShadow() was
deferred to avoid the obvious bugs updating the shadow would cause.
This sucks because it means we're always out by one frame, and it means
we always do two updates.
As the shadow is taken from the buffer, we can solve that problem by
updating the shadow before any painting at the same time that we update the
buffer. This means we don't need the deferring hack.
This patch also fixes a related issue that m_padding could have
changed after the buffer is rendered, but before painting. This would lead to rendering a mess.
This patch caches the relevant padding at the time the buffer is
created.
@Notmart, this is subtly different from the patch I showed you last night,
for me it fixes things without your other patch, but I don't know. If it doesn't it's
still (IMHO) a lot cleaner.
Test Plan:
Ran an Aurorae theme
Maximised, restored, resized. Everything.
Reviewers: #plasma, graesslin
Reviewed By: #plasma, graesslin
Subscribers: graesslin, plasma-devel
Tags: #plasma
Differential Revision: https://phabricator.kde.org/D4990
Summary:
To ease development of touchpad gestures it's useful to have support in
the nested Wayland platform.
Test Plan: Shown in Debug Console of nested KWin
Reviewers: #kwin, #plasma
Subscribers: plasma-devel, kwin
Tags: #kwin
Differential Revision: https://phabricator.kde.org/D5059
The logic on page flips was inconsistent in the sense, that it should never
release a GBM buffer before it's not used (i.e. viewable on the display)
anymore. This happened unintended until now (on page flip we never really
did something useful in the else statement, because if we're here it's not
a GBM buffer anyway).
With this patch we:
* delete on page flips always only the old buffer, which is not used anymore
* release the buffer earlier on interrupts like display disconnect in order
to be able to destroy the EGL context
Test Plan:
Tested in non atomic mode (atomic mode is obsolete right now until my other
WIP patch D4539 is ready to be merged): Login, logout, suspend, normal use.
Reviewers: #kwin, graesslin
Reviewed By: #kwin, graesslin
Subscribers: plasma-devel, kwin
Tags: #kwin
Differential Revision: https://phabricator.kde.org/D5060
Summary:
update m_visibleRectBeforeGeometryUpdate when the padding
change signal gets emitted: aurorae updates its shadow
and postentially shadow size asynchronously after repainting.
that would make the first addRepaintDuringGeometryUpdates
when the winow is moved *for the first time* have a wrong
m_visibleRectBeforeGeometryUpdate that doesn't take into
account the shadow, leaving some leftover shadow on screen
BUG:377670
Test Plan:
shadow leftover not reproducible anymore with maui's kwinrc
replaces D4989
tested both on master and together D4990, which should go in as well
Reviewers: #plasma, davidedmundson, graesslin
Reviewed By: #plasma, graesslin
Subscribers: plasma-devel, kwin, #kwin
Tags: #kwin
Differential Revision: https://phabricator.kde.org/D5078
Summary:
new logout effect: it's just a slow fade in of the logout
greeter (window is usable immediately tough
Test Plan: logout greeter now fades in without setting the window opacity manually
Reviewers: graesslin, #plasma
Reviewed By: graesslin, #plasma
Subscribers: broulik, plasma-devel, kwin, #kwin
Tags: #plasma
Differential Revision: https://phabricator.kde.org/D5045
Summary:
use a KPackage/PackageStructure for aurorae themes as well
Patch by Demitrius Belai
Reviewers: #plasma, graesslin
Reviewed By: #plasma, graesslin
Subscribers: graesslin, plasma-devel, kwin, #kwin
Tags: #plasma
Differential Revision: https://phabricator.kde.org/D4974
Summary:
as different windows can have different contrast region parameters,
store color matrices per window
BUG:339237
Test Plan: logout window doesn't break panel anymore
Reviewers: #plasma, graesslin
Reviewed By: #plasma, graesslin
Subscribers: broulik, plasma-devel, kwin, #kwin
Tags: #kwin
Differential Revision: https://phabricator.kde.org/D5048
Summary:
auto hidden windows were shown again when their geometry
changed, this was done for being as easy as possible as
the unhide zone changed, but the behavior looked very
annoying as autohide panels with an self resize taskbar
would unhide themselves every time any window gets open
or closed.
This makes the edge keep track of
windows that can resize/move themselves while auto hidden
Test Plan:
a self-resizing autohidden panel with a taskbar in it doesn't auto unhide
anymore when a window is opened or closed.
the unhide area gets properly updated
Reviewers: graesslin, #plasma
Reviewed By: graesslin, #plasma
Subscribers: luebking, plasma-devel, kwin, #kwin
Tags: #kwin
Differential Revision: https://phabricator.kde.org/D4718