mirror of
https://github.com/tomahawk-player/tomahawk.git
synced 2025-08-11 16:44:05 +02:00
Allow to show the setting dialog always, and disable +/- buttons till loaded
This commit is contained in:
@@ -113,7 +113,10 @@ SettingsDialog::SettingsDialog( QWidget *parent )
|
||||
{
|
||||
m_sipSpinner = new LoadingSpinner( ui->accountsView );
|
||||
m_sipSpinner->fadeIn();
|
||||
connect( Servent::instance(), SIGNAL( ready() ),m_sipSpinner, SLOT( fadeOut() ) );
|
||||
|
||||
ui->addSipButton->setEnabled( false );
|
||||
ui->removeSipButton->setEnabled( false );
|
||||
connect( Servent::instance(), SIGNAL( ready() ), this, SLOT( serventReady() ) );
|
||||
}
|
||||
|
||||
setupSipButtons();
|
||||
@@ -237,6 +240,13 @@ SettingsDialog::~SettingsDialog()
|
||||
delete ui;
|
||||
}
|
||||
|
||||
void
|
||||
SettingsDialog::serventReady()
|
||||
{
|
||||
m_sipSpinner->fadeOut();
|
||||
ui->addSipButton->setEnabled( true );
|
||||
ui->removeSipButton->setEnabled( true );
|
||||
}
|
||||
|
||||
void
|
||||
SettingsDialog::createIcons()
|
||||
|
@@ -101,6 +101,7 @@ private slots:
|
||||
void sipCreateConfigClosed( int value );
|
||||
|
||||
void changePage( QListWidgetItem*, QListWidgetItem* );
|
||||
void serventReady();
|
||||
|
||||
private:
|
||||
void createIcons();
|
||||
|
@@ -347,12 +347,6 @@ TomahawkWindow::setupSignals()
|
||||
ui->menuWindow->menuAction()->setVisible( false );
|
||||
#endif
|
||||
|
||||
if ( !Servent::instance()->isReady() )
|
||||
{
|
||||
ui->actionPreferences->setEnabled( false );
|
||||
connect( Servent::instance(), SIGNAL( ready() ), this, SLOT( enablePreferences() ) );
|
||||
}
|
||||
|
||||
// <SipHandler>
|
||||
connect( SipHandler::instance(), SIGNAL( connected( SipPlugin* ) ), SLOT( onSipConnected() ) );
|
||||
connect( SipHandler::instance(), SIGNAL( disconnected( SipPlugin* ) ), SLOT( onSipDisconnected() ) );
|
||||
@@ -711,12 +705,6 @@ TomahawkWindow::checkForUpdates()
|
||||
#endif
|
||||
}
|
||||
|
||||
void
|
||||
TomahawkWindow::enablePreferences()
|
||||
{
|
||||
ui->actionPreferences->setEnabled( true );
|
||||
}
|
||||
|
||||
|
||||
void
|
||||
TomahawkWindow::onSearch( const QString& search )
|
||||
|
@@ -89,7 +89,6 @@ private slots:
|
||||
|
||||
void showAboutTomahawk();
|
||||
void checkForUpdates();
|
||||
void enablePreferences();
|
||||
|
||||
void onSipPluginAdded( SipPlugin* p );
|
||||
void onSipPluginRemoved( SipPlugin* p );
|
||||
|
Reference in New Issue
Block a user