Members of the KDE Community are recommended to subscribe to the kde-community mailing list at to allow them to participate in important discussions and receive other important announcements

Commit 5e24bed3 authored by Vlad Zahorodnii's avatar Vlad Zahorodnii

[effects/cube] Port to TimeLine

Summary: Depends on D13740

Test Plan: "Activated" the desktop cube, animations still work.

Reviewers: #kwin, davidedmundson

Reviewed By: #kwin, davidedmundson

Subscribers: kwin

Tags: #kwin

Differential Revision:
parent 0be5010c
This diff is collapsed.
......@@ -26,7 +26,6 @@ along with this program. If not, see <>.
#include <QObject>
#include <QQueue>
#include <QMatrix4x4>
#include <QTimeLine>
#include <QFont>
#include "cube_inside.h"
#include "cube_proxy.h"
......@@ -42,7 +41,7 @@ class CubeEffect
Q_PROPERTY(bool opacityDesktopOnly READ isOpacityDesktopOnly)
Q_PROPERTY(bool displayDesktopName READ isDisplayDesktopName)
Q_PROPERTY(bool reflection READ isReflection)
Q_PROPERTY(int rotationDuration READ configuredRotationDuration)
Q_PROPERTY(std::chrono::milliseconds rotationDuration READ configuredRotationDuration)
Q_PROPERTY(QColor backgroundColor READ configuredBackgroundColor)
Q_PROPERTY(QColor capColor READ configuredCapColor)
Q_PROPERTY(bool paintCaps READ isPaintCaps)
......@@ -93,7 +92,7 @@ public:
bool isReflection() const {
return reflection;
int configuredRotationDuration() const {
std::chrono::milliseconds configuredRotationDuration() const {
return rotationDuration;
QColor configuredBackgroundColor() const {
......@@ -204,17 +203,17 @@ private:
float currentAngle;
int startFrontDesktop;
AnimationState animationState;
QTimeLine timeLine;
TimeLine timeLine;
QQueue<AnimationState> animations;
// vertical
float verticalStartAngle;
float verticalCurrentAngle;
VerticalAnimationState verticalAnimationState;
QTimeLine verticalTimeLine;
TimeLine verticalTimeLine;
QQueue<VerticalAnimationState> verticalAnimations;
bool reflectionPainting;
int rotationDuration;
std::chrono::milliseconds rotationDuration;
int activeScreen;
bool bottomCap;
bool closeOnMouseRelease;
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