mirror of
https://github.com/tomahawk-player/tomahawk.git
synced 2025-08-22 05:33:32 +02:00
* Changed tomahawkLoaded handling.
This commit is contained in:
@@ -146,7 +146,6 @@ TomahawkApp::TomahawkApp( int& argc, char *argv[] )
|
|||||||
, m_mainwindow( 0 )
|
, m_mainwindow( 0 )
|
||||||
#endif
|
#endif
|
||||||
, m_headless( false )
|
, m_headless( false )
|
||||||
, m_loaded( false )
|
|
||||||
{
|
{
|
||||||
if ( arguments().contains( "--help" ) || arguments().contains( "-h" ) )
|
if ( arguments().contains( "--help" ) || arguments().contains( "-h" ) )
|
||||||
{
|
{
|
||||||
@@ -158,7 +157,6 @@ TomahawkApp::TomahawkApp( int& argc, char *argv[] )
|
|||||||
setOrganizationDomain( QLatin1String( TOMAHAWK_ORGANIZATION_DOMAIN ) );
|
setOrganizationDomain( QLatin1String( TOMAHAWK_ORGANIZATION_DOMAIN ) );
|
||||||
setApplicationName( QLatin1String( TOMAHAWK_APPLICATION_NAME ) );
|
setApplicationName( QLatin1String( TOMAHAWK_APPLICATION_NAME ) );
|
||||||
setApplicationVersion( QLatin1String( TOMAHAWK_VERSION ) );
|
setApplicationVersion( QLatin1String( TOMAHAWK_VERSION ) );
|
||||||
connect( this, SIGNAL( tomahawkLoaded() ), SLOT( initEnergyEventHandler() ) );
|
|
||||||
|
|
||||||
registerMetaTypes();
|
registerMetaTypes();
|
||||||
TomahawkUtils::installTranslator( this );
|
TomahawkUtils::installTranslator( this );
|
||||||
@@ -566,6 +564,7 @@ TomahawkApp::initFactoriesForAccountManager()
|
|||||||
Tomahawk::Accounts::AccountManager::instance()->loadFromConfig();
|
Tomahawk::Accounts::AccountManager::instance()->loadFromConfig();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
void
|
void
|
||||||
TomahawkApp::initEnergyEventHandler()
|
TomahawkApp::initEnergyEventHandler()
|
||||||
{
|
{
|
||||||
@@ -590,9 +589,6 @@ TomahawkApp::initSIP()
|
|||||||
tDebug( LOGINFO ) << "Connecting SIP classes";
|
tDebug( LOGINFO ) << "Connecting SIP classes";
|
||||||
Accounts::AccountManager::instance()->initSIP();
|
Accounts::AccountManager::instance()->initSIP();
|
||||||
}
|
}
|
||||||
|
|
||||||
m_loaded = true;
|
|
||||||
emit tomahawkLoaded();
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@@ -684,6 +680,9 @@ TomahawkApp::onInfoSystemReady()
|
|||||||
// Make sure to do this after main window is inited
|
// Make sure to do this after main window is inited
|
||||||
Tomahawk::enableFullscreen( m_mainwindow );
|
Tomahawk::enableFullscreen( m_mainwindow );
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
initEnergyEventHandler();
|
||||||
|
emit tomahawkLoaded();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@@ -812,10 +811,3 @@ TomahawkApp::mainWindow() const
|
|||||||
{
|
{
|
||||||
return m_mainwindow;
|
return m_mainwindow;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
bool
|
|
||||||
TomahawkApp::isTomahawkLoaded() const
|
|
||||||
{
|
|
||||||
return m_loaded;
|
|
||||||
}
|
|
||||||
|
@@ -95,8 +95,6 @@ public:
|
|||||||
// PlatformInterface
|
// PlatformInterface
|
||||||
virtual bool loadUrl( const QString& url );
|
virtual bool loadUrl( const QString& url );
|
||||||
|
|
||||||
bool isTomahawkLoaded() const;
|
|
||||||
|
|
||||||
// reimplemented from QApplication/QCoreApplication
|
// reimplemented from QApplication/QCoreApplication
|
||||||
virtual bool notify( QObject* receiver, QEvent* e );
|
virtual bool notify( QObject* receiver, QEvent* e );
|
||||||
|
|
||||||
@@ -144,7 +142,7 @@ private:
|
|||||||
TomahawkWindow* m_mainwindow;
|
TomahawkWindow* m_mainwindow;
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
bool m_headless, m_loaded;
|
bool m_headless;
|
||||||
|
|
||||||
QPointer< QxtHttpServerConnector > m_connector;
|
QPointer< QxtHttpServerConnector > m_connector;
|
||||||
QPointer< QxtHttpSessionManager > m_session;
|
QPointer< QxtHttpSessionManager > m_session;
|
||||||
|
Reference in New Issue
Block a user