1
0
mirror of https://github.com/tomahawk-player/tomahawk.git synced 2025-08-05 05:37:29 +02:00

* QueueView waits for the Pipeline to become ready.

This commit is contained in:
Christian Muehlhaeuser
2013-06-08 10:19:01 +02:00
parent a900048c8a
commit cee71b9b08
2 changed files with 11 additions and 2 deletions

View File

@@ -24,6 +24,7 @@
#include "widgets/HeaderLabel.h" #include "widgets/HeaderLabel.h"
#include "playlist/QueueProxyModel.h" #include "playlist/QueueProxyModel.h"
#include "utils/Logger.h" #include "utils/Logger.h"
#include "Pipeline.h"
#include "PlaylistView.h" #include "PlaylistView.h"
#include "Source.h" #include "Source.h"
#include "TomahawkSettings.h" #include "TomahawkSettings.h"
@@ -67,7 +68,14 @@ QueueView::QueueView( AnimatedSplitter* parent )
// Set initial state // Set initial state
onHidden( this, false ); onHidden( this, false );
restoreState(); if ( Pipeline::instance()->isRunning() )
{
restoreState();
}
else
{
connect( Pipeline::instance(), SIGNAL( running() ), SLOT( restoreState() ) );
}
} }

View File

@@ -61,9 +61,10 @@ private slots:
void updateLabel(); void updateLabel();
void onAnimationFinished(); void onAnimationFinished();
void restoreState();
private: private:
void saveState(); void saveState();
void restoreState();
Ui::QueueView* ui; Ui::QueueView* ui;
QTimer* m_dragTimer; QTimer* m_dragTimer;