Commit 85e54c63 authored by Jan Möbius's avatar Jan Möbius

Fix anoying bug, where slide window stays open, when leaving it during animation

git-svn-id: http://www.openflipper.org/svnrepo/OpenFlipper/branches/Free@12458 383ad7c9-94d9-4d36-a494-682f7c89f535
parent e5ee271b
......@@ -322,9 +322,17 @@ void QtSlideWindow::updateParentGeometry() {
//-----------------------------------------------------------------------------
#include <iostream>
void QtSlideWindow::animationFinished() {
animating_ = false;
// If we reached up position,
// check if the mouse is still inside (could leave in between as we block the leave event
// when animating to avoid flickering
// If mouse is not inside anymore, we start the countdown for slideDown
if ( !down_ && !isUnderMouse() )
timer_->start(WAIT_UNTIL_SLIDE_DOWN);
}
//-----------------------------------------------------------------------------
......
......@@ -138,10 +138,10 @@ class DLLEXPORT QtSlideWindow : public QGraphicsProxyWidget
/// Slide widget down
void slideDown();
// Slot is called whenever the animation is finished
/// Slot is called whenever the animation is finished
void animationFinished();
// Start actual slide down
/// Start actual slide down
void startSlideDownAnimation();
private:
......
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