From c470e49aa9d6c97e805eb193afab97e9e19814eb Mon Sep 17 00:00:00 2001 From: Konstantinos Sideris Date: Tue, 16 May 2017 21:21:31 +0300 Subject: Add geometry animation on emoji picker --- include/EmojiPanel.h | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) (limited to 'include') diff --git a/include/EmojiPanel.h b/include/EmojiPanel.h index 5e053216..99c8fa63 100644 --- a/include/EmojiPanel.h +++ b/include/EmojiPanel.h @@ -20,6 +20,7 @@ #include #include +#include #include #include #include @@ -47,13 +48,22 @@ protected: private: void showEmojiCategory(const EmojiCategory *category); - QPropertyAnimation *animation_; + QPropertyAnimation *opacity_anim_; + QPropertyAnimation *size_anim_; QGraphicsOpacityEffect *opacity_; + QParallelAnimationGroup *animation_; EmojiProvider emoji_provider_; QScrollArea *scroll_area_; + // Panel dimensions. + const int WIDTH = 370; + const int HEIGHT = 350; + + const int ANIMATION_DURATION = 100; + const int ANIMATION_OFFSET = 50; + const int category_icon_size_ = 20; }; -- cgit 1.5.1