Skip to content

Commit

Permalink
* Style cleanup for GlobalActionManager.
Browse files Browse the repository at this point in the history
  • Loading branch information
muesli committed Nov 14, 2012
1 parent f5ff0c4 commit 7a64565
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 9 deletions.
9 changes: 3 additions & 6 deletions src/libtomahawk/GlobalActionManager.cpp
Expand Up @@ -1110,10 +1110,10 @@ GlobalActionManager::playSpotify( const QUrl& url )
return true;
}


void
GlobalActionManager::playNow( const query_ptr& q )
{

Pipeline::instance()->resolve( q, true );

m_waitingToPlay = q;
Expand Down Expand Up @@ -1270,10 +1270,8 @@ GlobalActionManager::postShortenFinished()
QNetworkReply* reply = qobject_cast<QNetworkReply*>( sender() );
Q_ASSERT( reply );
const QByteArray raw = reply->readAll();
qDebug() << "GOT REPLYL" << raw;

const QUrl url = QUrl::fromUserInput( raw );
qDebug() << "GOT POSTED SHORT URL:" << url.toString();
QClipboard* cb = QApplication::clipboard();

const QByteArray data = percentEncode( url );
Expand All @@ -1288,8 +1286,7 @@ GlobalActionManager::postShortenFinished()
void
GlobalActionManager::shortenLinkRequestError( QNetworkReply::NetworkError error )
{
qDebug() << Q_FUNC_INFO;
qDebug() << "Network Error: " << error;
tDebug() << Q_FUNC_INFO << "Network Error:" << error;

QNetworkReply *reply = qobject_cast<QNetworkReply*>( sender() );

Expand Down Expand Up @@ -1417,7 +1414,7 @@ GlobalActionManager::hostname() const


QByteArray
GlobalActionManager::percentEncode (const QUrl &url ) const
GlobalActionManager::percentEncode( const QUrl& url ) const
{
QByteArray data = url.toEncoded();

Expand Down
6 changes: 3 additions & 3 deletions src/libtomahawk/GlobalActionManager.h
Expand Up @@ -51,7 +51,7 @@ class DLLEXPORT GlobalActionManager : public QObject

public slots:
void shortenLink( const QUrl& url, const QVariant &callbackObj = QVariant() );

#ifndef ENABLE_HEADLESS

/// Takes a spotify link and performs the default open action on it
Expand Down Expand Up @@ -96,7 +96,7 @@ private slots:
void playlistReadyToShow();

void xspfCreated( const QByteArray& xspf );

void playOrQueueNow( const Tomahawk::query_ptr& );
void playNow( const Tomahawk::query_ptr& );
#endif
Expand All @@ -115,7 +115,7 @@ private slots:
bool handleAutoPlaylistCommand( const QUrl& url );
bool handleImportCommand( const QUrl& url );
bool doQueueAdd( const QStringList& parts, const QList< QPair< QString, QString > >& queryItems );

bool playSpotify( const QUrl& url );
bool queueSpotify( const QStringList& parts, const QList< QPair< QString, QString > >& queryItems );
bool playRdio( const QUrl& url );
Expand Down

0 comments on commit 7a64565

Please sign in to comment.