1
0
mirror of https://github.com/tomahawk-player/tomahawk.git synced 2025-03-13 20:39:57 +01:00

Some more fixes

This commit is contained in:
Leo Franchi 2012-07-03 09:53:49 -04:00
parent 427a26e034
commit 35a0db7a07
2 changed files with 12 additions and 4 deletions

View File

@ -207,6 +207,10 @@ Result::toQuery()
if ( m_query.isNull() )
{
m_query = Tomahawk::Query::get( artist()->name(), track(), album()->name() );
if ( m_query.isNull() )
return query_ptr();
m_query->setAlbumPos( albumpos() );
m_query->setDiscNumber( discnumber() );
m_query->setDuration( duration() );

View File

@ -43,8 +43,8 @@ SpotifyAccountConfig::SpotifyAccountConfig( SpotifyAccount *account )
connect( m_ui->loginButton, SIGNAL( clicked( bool ) ), this, SLOT( doLogin() ) );
connect( m_ui->usernameEdit, SIGNAL( textChanged( QString ) ), this, SLOT( resetLoginButton() ) );
connect( m_ui->passwordEdit, SIGNAL( textChanged( QString ) ), this, SLOT( resetLoginButton() ) );
connect( m_ui->usernameEdit, SIGNAL( textEdited( QString ) ), this, SLOT( resetLoginButton() ) );
connect( m_ui->passwordEdit, SIGNAL( textEdited( QString ) ), this, SLOT( resetLoginButton() ) );
loadFromConfig();
m_playlistsLoading = new AnimatedSpinner( m_ui->playlistList );
@ -151,6 +151,7 @@ SpotifyAccountConfig::doLogin()
m_isLoggedIn = false;
m_loggedInManually = false;
m_verifiedUsername.clear();
m_ui->playlistList->clear();
emit logout();
showLoggedOut();
}
@ -217,7 +218,10 @@ SpotifyAccountConfig::showLoggedOut()
void
SpotifyAccountConfig::resetLoginButton()
{
m_ui->loginButton->setText( tr( "Log In" ) );
m_ui->loginButton->setEnabled( true );
if ( !m_isLoggedIn )
{
m_ui->loginButton->setText( tr( "Log In" ) );
m_ui->loginButton->setEnabled( true );
}
}