Commit 7b910c51 authored by Vlad Zahorodnii's avatar Vlad Zahorodnii
Browse files

[effects/morphingpopups] Don't animate popups when only shape changes

Summary:
The frame geometry stays still when only shape changes.

BUG: 416531

Reviewers: #kwin

Subscribers: kwin

Tags: #kwin

Differential Revision: https://phabricator.kde.org/D26809
parent e0df390d
...@@ -38,6 +38,13 @@ var morphingEffect = { ...@@ -38,6 +38,13 @@ var morphingEffect = {
//don't cross the whole screen: ugly //don't cross the whole screen: ugly
var distance = Math.abs(oldGeometry.x - newGeometry.x) + Math.abs(oldGeometry.y - newGeometry.y); var distance = Math.abs(oldGeometry.x - newGeometry.x) + Math.abs(oldGeometry.y - newGeometry.y);
if (newGeometry.x == oldGeometry.x &&
newGeometry.y == oldGeometry.y &&
newGeometry.width == oldGeometry.width &&
newGeometry.height == oldGeometry.height) {
return;
}
if (distance > (newGeometry.width + newGeometry.height) * 2) { if (distance > (newGeometry.width + newGeometry.height) * 2) {
if (window.moveAnimation) { if (window.moveAnimation) {
delete window.moveAnimation; delete window.moveAnimation;
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment