mirror of
https://github.com/tomahawk-player/tomahawk.git
synced 2025-04-20 07:52:30 +02:00
* Don't try to reconnect if the jabber authentication failed.
* Added basic "About Tomahawk" dialog.
This commit is contained in:
parent
92b6865a7e
commit
2a5c5f3562
@ -248,7 +248,7 @@ Servent::readyRead()
|
||||
{
|
||||
if( cc->id() == nodeid )
|
||||
{
|
||||
qDebug() << "Duplicate control connection detected, dropping:" << nodeid;
|
||||
qDebug() << "Duplicate control connection detected, dropping:" << nodeid << conntype;
|
||||
goto closeconnection;
|
||||
}
|
||||
}
|
||||
|
@ -489,10 +489,13 @@ TomahawkApp::jabberAuthError( int code, const QString& msg )
|
||||
.arg( "AUTH_ERROR" )
|
||||
.arg( (servent().externalPort() > 0) ? QString( "YES:%1" ).arg(servent().externalPort()) :"NO" ) );
|
||||
|
||||
QMessageBox::warning( m_mainwindow,
|
||||
"Jabber Auth Error",
|
||||
QString("Error connecting to Jabber (%1) %2").arg(code).arg(msg),
|
||||
QMessageBox::Ok );
|
||||
if ( code == gloox::ConnAuthenticationFailed )
|
||||
{
|
||||
QMessageBox::warning( m_mainwindow,
|
||||
"Jabber Auth Error",
|
||||
QString("Error connecting to Jabber (%1) %2").arg(code).arg(msg),
|
||||
QMessageBox::Ok );
|
||||
}
|
||||
}
|
||||
#endif
|
||||
|
||||
@ -621,13 +624,14 @@ TomahawkApp::jabberMessage( const QString& from, const QString& msg )
|
||||
}
|
||||
else
|
||||
{
|
||||
qDebug() << Q_FUNC_INFO << "THey should be conecting to us...";
|
||||
qDebug() << Q_FUNC_INFO << "They should be conecting to us...";
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
qDebug() << Q_FUNC_INFO << "THey are not visible, doing nothing atm";
|
||||
if( m_servent.visibleExternally() ) jabberPeerOnline( from ); // HACK FIXME
|
||||
qDebug() << Q_FUNC_INFO << "They are not visible, doing nothing atm";
|
||||
if ( m_servent.visibleExternally() )
|
||||
jabberPeerOnline( from ); // HACK FIXME
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -148,14 +148,10 @@ TomahawkWindow::setupSignals()
|
||||
SLOT( onPlaybackLoading( const Tomahawk::result_ptr& ) ) );
|
||||
|
||||
// <Menu Items>
|
||||
connect( ui->actionPreferences, SIGNAL( triggered() ),
|
||||
SLOT( showSettingsDialog() ) );
|
||||
|
||||
connect( ui->actionAddPeerManually, SIGNAL( triggered() ),
|
||||
SLOT( addPeerManually() ) );
|
||||
|
||||
connect( ui->actionRescanCollection, SIGNAL( triggered() ),
|
||||
SLOT( rescanCollectionManually() ) );
|
||||
connect( ui->actionPreferences, SIGNAL( triggered() ), SLOT( showSettingsDialog() ) );
|
||||
connect( ui->actionAddPeerManually, SIGNAL( triggered() ), SLOT( addPeerManually() ) );
|
||||
connect( ui->actionRescanCollection, SIGNAL( triggered() ), SLOT( rescanCollectionManually() ) );
|
||||
connect( ui->actionAbout_Tomahawk, SIGNAL( triggered() ), SLOT( showAboutTomahawk() ) );
|
||||
}
|
||||
|
||||
|
||||
@ -309,3 +305,10 @@ TomahawkWindow::setWindowTitle( const QString& title )
|
||||
QMainWindow::setWindowTitle( s + " - " + title );
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
void
|
||||
TomahawkWindow::showAboutTomahawk()
|
||||
{
|
||||
QMessageBox::about( this, "About Tomahawk", "Copyright 2010 Christian Muehlhaeuser <muesli@gmail.com>\nThanks to: Leo Franchi, Dominik Schmidt and Steve Robertson" );
|
||||
}
|
||||
|
@ -52,6 +52,8 @@ private slots:
|
||||
|
||||
void onPlaybackLoading( const Tomahawk::result_ptr& result );
|
||||
|
||||
void showAboutTomahawk();
|
||||
|
||||
private:
|
||||
void loadSettings();
|
||||
void saveSettings();
|
||||
|
@ -39,7 +39,7 @@
|
||||
<x>0</x>
|
||||
<y>0</y>
|
||||
<width>800</width>
|
||||
<height>22</height>
|
||||
<height>20</height>
|
||||
</rect>
|
||||
</property>
|
||||
<widget class="QMenu" name="menuSettings">
|
||||
@ -52,7 +52,6 @@
|
||||
<property name="title">
|
||||
<string>Music &Player</string>
|
||||
</property>
|
||||
<addaction name="actionAddPeerManually"/>
|
||||
<addaction name="actionRescanCollection"/>
|
||||
<addaction name="separator"/>
|
||||
<addaction name="actionExit"/>
|
||||
@ -65,9 +64,23 @@
|
||||
<addaction name="separator"/>
|
||||
<addaction name="actionLoadXSPF"/>
|
||||
</widget>
|
||||
<widget class="QMenu" name="menuNetwork">
|
||||
<property name="title">
|
||||
<string>Network</string>
|
||||
</property>
|
||||
<addaction name="actionAddPeerManually"/>
|
||||
</widget>
|
||||
<widget class="QMenu" name="menu_Help">
|
||||
<property name="title">
|
||||
<string>&Help</string>
|
||||
</property>
|
||||
<addaction name="actionAbout_Tomahawk"/>
|
||||
</widget>
|
||||
<addaction name="menuApp"/>
|
||||
<addaction name="menuPlaylist"/>
|
||||
<addaction name="menuNetwork"/>
|
||||
<addaction name="menuSettings"/>
|
||||
<addaction name="menu_Help"/>
|
||||
</widget>
|
||||
<widget class="QStatusBar" name="statusBar"/>
|
||||
<action name="actionExit">
|
||||
@ -109,6 +122,11 @@
|
||||
<string>Create &New Playlist...</string>
|
||||
</property>
|
||||
</action>
|
||||
<action name="actionAbout_Tomahawk">
|
||||
<property name="text">
|
||||
<string>About &Tomahawk</string>
|
||||
</property>
|
||||
</action>
|
||||
</widget>
|
||||
<layoutdefault spacing="6" margin="11"/>
|
||||
<customwidgets>
|
||||
|
Loading…
x
Reference in New Issue
Block a user