mirror of
https://github.com/tomahawk-player/tomahawk.git
synced 2025-08-11 16:44:05 +02:00
ui cleanup
This commit is contained in:
@@ -118,15 +118,11 @@ SettingsDialog::SettingsDialog( QWidget *parent )
|
|||||||
|
|
||||||
connect( m_accountModel, SIGNAL( createAccount( Tomahawk::Accounts::AccountFactory* ) ), this, SLOT( createAccountFromFactory( Tomahawk::Accounts::AccountFactory* ) ) );
|
connect( m_accountModel, SIGNAL( createAccount( Tomahawk::Accounts::AccountFactory* ) ), this, SLOT( createAccountFromFactory( Tomahawk::Accounts::AccountFactory* ) ) );
|
||||||
|
|
||||||
connect( ui->accountsView->selectionModel(), SIGNAL( selectionChanged( QItemSelection,QItemSelection ) ), this, SLOT( accountsSelectionChanged() ) );
|
|
||||||
|
|
||||||
if ( !Servent::instance()->isReady() )
|
if ( !Servent::instance()->isReady() )
|
||||||
{
|
{
|
||||||
m_sipSpinner = new LoadingSpinner( ui->accountsView );
|
m_sipSpinner = new LoadingSpinner( ui->accountsView );
|
||||||
m_sipSpinner->fadeIn();
|
m_sipSpinner->fadeIn();
|
||||||
|
|
||||||
ui->addNewServiceBtn->setEnabled( false );
|
|
||||||
ui->removeServiceBtn->setEnabled( false );
|
|
||||||
connect( Servent::instance(), SIGNAL( ready() ), this, SLOT( serventReady() ) );
|
connect( Servent::instance(), SIGNAL( ready() ), this, SLOT( serventReady() ) );
|
||||||
}
|
}
|
||||||
ui->staticHostName->setText( s->externalHostname() );
|
ui->staticHostName->setText( s->externalHostname() );
|
||||||
@@ -225,8 +221,6 @@ void
|
|||||||
SettingsDialog::serventReady()
|
SettingsDialog::serventReady()
|
||||||
{
|
{
|
||||||
m_sipSpinner->fadeOut();
|
m_sipSpinner->fadeOut();
|
||||||
ui->addNewServiceBtn->setEnabled( true );
|
|
||||||
ui->removeServiceBtn->setEnabled( true );
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@@ -424,20 +418,6 @@ SettingsDialog::onLastFmFinished()
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
void
|
|
||||||
SettingsDialog::accountsSelectionChanged()
|
|
||||||
{
|
|
||||||
if( !ui->accountsView->selectionModel()->selectedIndexes().isEmpty() )
|
|
||||||
{
|
|
||||||
ui->removeServiceBtn->setEnabled( true );
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
ui->addNewServiceBtn->setEnabled( false );
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
void
|
void
|
||||||
SettingsDialog::openAccountConfig( Account* account, bool showDelete )
|
SettingsDialog::openAccountConfig( Account* account, bool showDelete )
|
||||||
{
|
{
|
||||||
|
@@ -90,8 +90,6 @@ private slots:
|
|||||||
|
|
||||||
void createAccountFromFactory( Tomahawk::Accounts::AccountFactory* );
|
void createAccountFromFactory( Tomahawk::Accounts::AccountFactory* );
|
||||||
|
|
||||||
void accountsSelectionChanged();
|
|
||||||
|
|
||||||
void openAccountConfig( Tomahawk::Accounts::Account*, bool showDelete = false );
|
void openAccountConfig( Tomahawk::Accounts::Account*, bool showDelete = false );
|
||||||
void openAccountFactoryConfig( Tomahawk::Accounts::AccountFactory* );
|
void openAccountFactoryConfig( Tomahawk::Accounts::AccountFactory* );
|
||||||
void accountConfigClosed( int value );
|
void accountConfigClosed( int value );
|
||||||
|
@@ -97,12 +97,33 @@
|
|||||||
<property name="title">
|
<property name="title">
|
||||||
<string>Internet Sources</string>
|
<string>Internet Sources</string>
|
||||||
</property>
|
</property>
|
||||||
<layout class="QVBoxLayout" name="verticalLayout_14">
|
<layout class="QVBoxLayout" name="verticalLayout_8">
|
||||||
<property name="margin">
|
|
||||||
<number>2</number>
|
|
||||||
</property>
|
|
||||||
<item>
|
<item>
|
||||||
<layout class="QHBoxLayout" name="horizontalLayout_2"/>
|
<layout class="QHBoxLayout" name="horizontalLayout_2">
|
||||||
|
<item>
|
||||||
|
<spacer name="horizontalSpacer">
|
||||||
|
<property name="orientation">
|
||||||
|
<enum>Qt::Horizontal</enum>
|
||||||
|
</property>
|
||||||
|
<property name="sizeHint" stdset="0">
|
||||||
|
<size>
|
||||||
|
<width>40</width>
|
||||||
|
<height>20</height>
|
||||||
|
</size>
|
||||||
|
</property>
|
||||||
|
</spacer>
|
||||||
|
</item>
|
||||||
|
<item>
|
||||||
|
<widget class="QLabel" name="label">
|
||||||
|
<property name="text">
|
||||||
|
<string>Filter by capability:</string>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item>
|
||||||
|
<widget class="QComboBox" name="comboBox"/>
|
||||||
|
</item>
|
||||||
|
</layout>
|
||||||
</item>
|
</item>
|
||||||
<item>
|
<item>
|
||||||
<widget class="QListView" name="accountsView"/>
|
<widget class="QListView" name="accountsView"/>
|
||||||
@@ -519,9 +540,7 @@
|
|||||||
<header location="global">widgets/checkdirtree.h</header>
|
<header location="global">widgets/checkdirtree.h</header>
|
||||||
</customwidget>
|
</customwidget>
|
||||||
</customwidgets>
|
</customwidgets>
|
||||||
<resources>
|
<resources/>
|
||||||
<include location="../resources.qrc"/>
|
|
||||||
</resources>
|
|
||||||
<connections>
|
<connections>
|
||||||
<connection>
|
<connection>
|
||||||
<sender>buttonBox</sender>
|
<sender>buttonBox</sender>
|
||||||
|
Reference in New Issue
Block a user