Improved Last.fm scrobbling when connection is down

This commit is contained in:
Andrea Decorte 2011-04-28 10:32:56 +00:00
parent 23fbada6c4
commit 9dd45dbe82
58 changed files with 458 additions and 9 deletions

View File

@ -124,6 +124,7 @@ class Playlist : public QAbstractListModel {
LastFM_Seeked, // The user seeked so don't scrobble
LastFM_Error, // Tried to scrobble but got an error
LastFM_Invalid, // The song isn't suitable for scrobbling
LastFM_Queued, // Track added to the queue for scrobbling
};
static const char* kRowsMimetype;

View File

@ -112,10 +112,16 @@ void LastFMConfig::UpdatedSubscriberStatus(bool is_subscriber) {
ui_->subscriber_warning->hide();
ui_->warn_icon->hide();
} else {
ui_->subscriber_warning->setText(
tr("You will not be able to play Last.fm radio stations "
"as you are not a Last.fm subscriber."));
ui_->warn_icon->show();
if (service_->HasConnectionProblems()) {
ui_->subscriber_warning->setText(
tr("Clementine couldn't fetch your subscription status since there are problems "
"with your connection. Played tracks will be cached and sent later to Last.fm."));
} else {
ui_->subscriber_warning->setText(
tr("You will not be able to play Last.fm radio stations "
"as you are not a Last.fm subscriber."));
}
}
}
@ -143,8 +149,7 @@ void LastFMConfig::RefreshControls(bool authenticated) {
ui_->sign_out->setVisible(authenticated);
if (authenticated) {
ui_->status->setText(QString(tr("You're logged in as <b>%1</b>")).arg(lastfm::ws::Username));
}
else {
} else {
ui_->icon->setPixmap(IconLoader::Load("dialog-question").pixmap(16));
ui_->status->setText(tr("Please fill in the blanks to login into Last.fm"));

View File

@ -75,7 +75,8 @@ LastFMService::LastFMService(RadioModel* parent)
tag_list_(NULL),
custom_list_(NULL),
friends_list_(NULL),
neighbours_list_(NULL)
neighbours_list_(NULL),
connection_problems_(false)
{
ReloadSettings();
//we emit the signal the first time to be sure the buttons are in the right state
@ -253,6 +254,7 @@ void LastFMService::Authenticate(const QString& username, const QString& passwor
QNetworkReply* reply = lastfm::ws::post(params);
connect(reply, SIGNAL(finished()), SLOT(AuthenticateReplyFinished()));
// If we need more detailed error reporting, handle error(NetworkError) signal
}
void LastFMService::SignOut() {
@ -326,15 +328,24 @@ void LastFMService::UpdateSubscriberStatusFinished() {
throw std::runtime_error("");
#endif
connection_problems_ = false;
QString subscriber = lfm["user"]["subscriber"].text();
const bool is_subscriber = (subscriber.toInt() == 1);
QSettings settings;
settings.beginGroup(kSettingsGroup);
settings.setValue("Subscriber", is_subscriber);
qLog(Info) << lastfm::ws::Username << "Subscriber status:" << is_subscriber;
emit UpdatedSubscriberStatus(is_subscriber);
} catch (lastfm::ws::ParseError e) {
// The connection to the server is unavailable
connection_problems_ = true;
qLog(Error) << "Last.fm parse error: " << e.enumValue();
emit UpdatedSubscriberStatus(false);
} catch (std::runtime_error& e) {
connection_problems_ = true;
qLog(Error) << e.what();
emit UpdatedSubscriberStatus(false);
}
}
@ -516,7 +527,11 @@ void LastFMService::Scrobble() {
return;
scrobbler_->cache(last_track_);
// Let's mark a track as cached, useful when the connection is down
emit ScrobblerStatus(30);
scrobbler_->submit();
already_scrobbled_ = true;
}

View File

@ -98,6 +98,7 @@ class LastFMService : public RadioService {
bool IsScrobblingEnabled() const { return scrobbling_enabled_; }
bool AreButtonsVisible() const { return buttons_visible_; }
bool IsScrobbleButtonVisible() const { return scrobble_button_visible_; }
bool HasConnectionProblems() const { return connection_problems_; }
void Authenticate(const QString& username, const QString& password);
void SignOut();
@ -203,6 +204,9 @@ class LastFMService : public RadioService {
QStandardItem* neighbours_list_;
QHash<lastfm::Track, QString> art_urls_;
// Useful to inform the user that we can't scrobble right now
bool connection_problems_;
};
#endif // LASTFMSERVICE_H

View File

@ -53,6 +53,7 @@ public:
LastFM_Seeked, // The user seeked so don't scrobble
LastFM_Error, // Tried to scrobble but got an error
LastFM_Invalid, // The song isn't suitable for scrobbling
LastFM_Queued, // Track added to the queue for scrobbling
};
static const char* kRowsMimetype;

View File

@ -568,6 +568,11 @@ msgid ""
"installed Clementine properly."
msgstr ""
msgid ""
"Clementine couldn't fetch your subscription status since there are problems "
"with your connection. Played tracks will be cached and sent later to Last.fm."
msgstr ""
msgid "Clementine image viewer"
msgstr ""
@ -2445,6 +2450,9 @@ msgstr ""
msgid "Speex"
msgstr ""
msgid "Spotify"
msgstr ""
msgid "Standard"
msgstr ""

View File

@ -576,6 +576,11 @@ msgstr ""
"Clementine не можа загрузіць якою-небудзь візуалізацыю projectM. Калі ласка, "
"праверце, што ўстанавілі Clementine правільна."
msgid ""
"Clementine couldn't fetch your subscription status since there are problems "
"with your connection. Played tracks will be cached and sent later to Last.fm."
msgstr ""
msgid "Clementine image viewer"
msgstr "Прагляд малюнкаў у Clementine"
@ -2459,6 +2464,9 @@ msgstr ""
msgid "Speex"
msgstr ""
msgid "Spotify"
msgstr ""
msgid "Standard"
msgstr ""

View File

@ -584,6 +584,11 @@ msgstr ""
"Клементин не можа да зареди никаква проекМ визуализация.Проверете дали сте "
"инсталирали Клементин правилно."
msgid ""
"Clementine couldn't fetch your subscription status since there are problems "
"with your connection. Played tracks will be cached and sent later to Last.fm."
msgstr ""
msgid "Clementine image viewer"
msgstr "Клементин мениджър на изображения"
@ -2488,6 +2493,9 @@ msgstr "Сортиране"
msgid "Speex"
msgstr ""
msgid "Spotify"
msgstr ""
msgid "Standard"
msgstr ""

View File

@ -581,6 +581,11 @@ msgstr ""
"N'eo ket bet gouest Clementine da gargañ diskwel porjectM. Gwiriekait ez eo "
"staliet mat Clementine."
msgid ""
"Clementine couldn't fetch your subscription status since there are problems "
"with your connection. Played tracks will be cached and sent later to Last.fm."
msgstr ""
msgid "Clementine image viewer"
msgstr "Gweler skeudennoù Clementine"
@ -2476,6 +2481,9 @@ msgstr ""
msgid "Speex"
msgstr ""
msgid "Spotify"
msgstr ""
msgid "Standard"
msgstr ""

View File

@ -581,6 +581,11 @@ msgstr ""
"Clementin nije mogao učitati projectM vizualizacije. Provjerite da li ste "
"instalirali Clementine kako treba."
msgid ""
"Clementine couldn't fetch your subscription status since there are problems "
"with your connection. Played tracks will be cached and sent later to Last.fm."
msgstr ""
msgid "Clementine image viewer"
msgstr "Clementine preglednik slika"
@ -2462,6 +2467,9 @@ msgstr ""
msgid "Speex"
msgstr ""
msgid "Spotify"
msgstr ""
msgid "Standard"
msgstr ""

View File

@ -588,6 +588,11 @@ msgstr ""
"Clementine no pot carregar cap visualització de projectM. Asseguri's que té "
"instal·lat Clementine correctament."
msgid ""
"Clementine couldn't fetch your subscription status since there are problems "
"with your connection. Played tracks will be cached and sent later to Last.fm."
msgstr ""
msgid "Clementine image viewer"
msgstr "Visor d'imatges Clementine"
@ -2482,6 +2487,9 @@ msgstr ""
msgid "Speex"
msgstr ""
msgid "Spotify"
msgstr ""
msgid "Standard"
msgstr ""

View File

@ -586,6 +586,11 @@ msgstr ""
"Clementine se nepodařilo nahrát žádné vizualizace z projectM. Ověřte, že "
"jste Clementine nainstalovali správně."
msgid ""
"Clementine couldn't fetch your subscription status since there are problems "
"with your connection. Played tracks will be cached and sent later to Last.fm."
msgstr ""
msgid "Clementine image viewer"
msgstr "Prohlížeč obrázků pro Clementine"
@ -2485,6 +2490,9 @@ msgstr "Třídění"
msgid "Speex"
msgstr ""
msgid "Spotify"
msgstr ""
msgid "Standard"
msgstr ""

View File

@ -568,6 +568,11 @@ msgid ""
"installed Clementine properly."
msgstr ""
msgid ""
"Clementine couldn't fetch your subscription status since there are problems "
"with your connection. Played tracks will be cached and sent later to Last.fm."
msgstr ""
msgid "Clementine image viewer"
msgstr ""
@ -2445,6 +2450,9 @@ msgstr ""
msgid "Speex"
msgstr ""
msgid "Spotify"
msgstr ""
msgid "Standard"
msgstr ""

View File

@ -569,6 +569,11 @@ msgid ""
"installed Clementine properly."
msgstr ""
msgid ""
"Clementine couldn't fetch your subscription status since there are problems "
"with your connection. Played tracks will be cached and sent later to Last.fm."
msgstr ""
msgid "Clementine image viewer"
msgstr ""
@ -2450,6 +2455,9 @@ msgstr ""
msgid "Speex"
msgstr ""
msgid "Spotify"
msgstr ""
msgid "Standard"
msgstr ""

View File

@ -591,6 +591,11 @@ msgstr ""
"Clementine konnte keine projectM-Visualisierungen laden. Überprüfen Sie Ihre "
"Installation."
msgid ""
"Clementine couldn't fetch your subscription status since there are problems "
"with your connection. Played tracks will be cached and sent later to Last.fm."
msgstr ""
msgid "Clementine image viewer"
msgstr "Clementine Bildbetrachter"
@ -2494,6 +2499,9 @@ msgstr "Sortierung"
msgid "Speex"
msgstr ""
msgid "Spotify"
msgstr ""
msgid "Standard"
msgstr ""

View File

@ -595,6 +595,11 @@ msgstr ""
"Ο Clementine δεν μπορεί να φορτώσει κάποιο projectM οπτικό εφέ. Βεβαιωθείτε "
"πως έχετε εγκαταστήσει τον Clementine σωστά."
msgid ""
"Clementine couldn't fetch your subscription status since there are problems "
"with your connection. Played tracks will be cached and sent later to Last.fm."
msgstr ""
msgid "Clementine image viewer"
msgstr "Προβολή εικόνων του Clementine"
@ -2505,6 +2510,9 @@ msgstr "Ταξινόμηση"
msgid "Speex"
msgstr ""
msgid "Spotify"
msgstr ""
msgid "Standard"
msgstr ""

View File

@ -568,6 +568,11 @@ msgid ""
"installed Clementine properly."
msgstr ""
msgid ""
"Clementine couldn't fetch your subscription status since there are problems "
"with your connection. Played tracks will be cached and sent later to Last.fm."
msgstr ""
msgid "Clementine image viewer"
msgstr ""
@ -2445,6 +2450,9 @@ msgstr ""
msgid "Speex"
msgstr ""
msgid "Spotify"
msgstr ""
msgid "Standard"
msgstr ""

View File

@ -568,6 +568,11 @@ msgid ""
"installed Clementine properly."
msgstr ""
msgid ""
"Clementine couldn't fetch your subscription status since there are problems "
"with your connection. Played tracks will be cached and sent later to Last.fm."
msgstr ""
msgid "Clementine image viewer"
msgstr ""
@ -2449,6 +2454,9 @@ msgstr ""
msgid "Speex"
msgstr ""
msgid "Spotify"
msgstr ""
msgid "Standard"
msgstr ""

View File

@ -568,6 +568,11 @@ msgid ""
"installed Clementine properly."
msgstr ""
msgid ""
"Clementine couldn't fetch your subscription status since there are problems "
"with your connection. Played tracks will be cached and sent later to Last.fm."
msgstr ""
msgid "Clementine image viewer"
msgstr ""
@ -2446,6 +2451,9 @@ msgstr ""
msgid "Speex"
msgstr ""
msgid "Spotify"
msgstr ""
msgid "Standard"
msgstr ""

View File

@ -568,6 +568,11 @@ msgid ""
"installed Clementine properly."
msgstr ""
msgid ""
"Clementine couldn't fetch your subscription status since there are problems "
"with your connection. Played tracks will be cached and sent later to Last.fm."
msgstr ""
msgid "Clementine image viewer"
msgstr ""
@ -2445,6 +2450,9 @@ msgstr ""
msgid "Speex"
msgstr ""
msgid "Spotify"
msgstr ""
msgid "Standard"
msgstr ""

View File

@ -595,6 +595,11 @@ msgstr ""
"Clementine no puede cargar ninguna visualización de projectM. Asegúrese que "
"tiene instalado Clementine adecuadamente."
msgid ""
"Clementine couldn't fetch your subscription status since there are problems "
"with your connection. Played tracks will be cached and sent later to Last.fm."
msgstr ""
msgid "Clementine image viewer"
msgstr "Visor de imágenes de Clementine"
@ -2503,6 +2508,9 @@ msgstr "Ordenando"
msgid "Speex"
msgstr ""
msgid "Spotify"
msgstr ""
msgid "Standard"
msgstr ""

View File

@ -568,6 +568,11 @@ msgid ""
"installed Clementine properly."
msgstr ""
msgid ""
"Clementine couldn't fetch your subscription status since there are problems "
"with your connection. Played tracks will be cached and sent later to Last.fm."
msgstr ""
msgid "Clementine image viewer"
msgstr ""
@ -2446,6 +2451,9 @@ msgstr "Sorteerimine"
msgid "Speex"
msgstr ""
msgid "Spotify"
msgstr ""
msgid "Standard"
msgstr ""

View File

@ -568,6 +568,11 @@ msgid ""
"installed Clementine properly."
msgstr ""
msgid ""
"Clementine couldn't fetch your subscription status since there are problems "
"with your connection. Played tracks will be cached and sent later to Last.fm."
msgstr ""
msgid "Clementine image viewer"
msgstr ""
@ -2445,6 +2450,9 @@ msgstr ""
msgid "Speex"
msgstr ""
msgid "Spotify"
msgstr ""
msgid "Standard"
msgstr ""

View File

@ -579,6 +579,11 @@ msgstr ""
"Clementine epäonnistui projectM-visualisoinnin esittämisessä. Varmista "
"Clementine-asennuksen toimivuus."
msgid ""
"Clementine couldn't fetch your subscription status since there are problems "
"with your connection. Played tracks will be cached and sent later to Last.fm."
msgstr ""
msgid "Clementine image viewer"
msgstr ""
@ -2468,6 +2473,9 @@ msgstr "Järjestys"
msgid "Speex"
msgstr ""
msgid "Spotify"
msgstr ""
msgid "Standard"
msgstr ""

View File

@ -596,6 +596,11 @@ msgstr ""
"Clementine n'a pu charger les visualisations projectM. Vérifiez que "
"Clementine est installé correctement."
msgid ""
"Clementine couldn't fetch your subscription status since there are problems "
"with your connection. Played tracks will be cached and sent later to Last.fm."
msgstr ""
msgid "Clementine image viewer"
msgstr "Visionneur d'images de Clementine"
@ -2507,6 +2512,9 @@ msgstr "Tri"
msgid "Speex"
msgstr ""
msgid "Spotify"
msgstr ""
msgid "Standard"
msgstr ""

View File

@ -576,6 +576,11 @@ msgstr ""
"Clementine non pode carregar ningunha visualización de projectM. Asegúrese "
"que ten instalado Clementine adecuadamente."
msgid ""
"Clementine couldn't fetch your subscription status since there are problems "
"with your connection. Played tracks will be cached and sent later to Last.fm."
msgstr ""
msgid "Clementine image viewer"
msgstr ""
@ -2454,6 +2459,9 @@ msgstr ""
msgid "Speex"
msgstr ""
msgid "Spotify"
msgstr ""
msgid "Standard"
msgstr ""

View File

@ -578,6 +578,11 @@ msgstr ""
"Clementine לא יכל לטעון אפקטים חזותיים של projectM. וודא שהתקנת את "
"Clementine כמו שצריך."
msgid ""
"Clementine couldn't fetch your subscription status since there are problems "
"with your connection. Played tracks will be cached and sent later to Last.fm."
msgstr ""
msgid "Clementine image viewer"
msgstr "מציג התמונות של Clementine"
@ -2465,6 +2470,9 @@ msgstr "מיון"
msgid "Speex"
msgstr ""
msgid "Spotify"
msgstr ""
msgid "Standard"
msgstr ""

View File

@ -568,6 +568,11 @@ msgid ""
"installed Clementine properly."
msgstr ""
msgid ""
"Clementine couldn't fetch your subscription status since there are problems "
"with your connection. Played tracks will be cached and sent later to Last.fm."
msgstr ""
msgid "Clementine image viewer"
msgstr ""
@ -2445,6 +2450,9 @@ msgstr ""
msgid "Speex"
msgstr ""
msgid "Spotify"
msgstr ""
msgid "Standard"
msgstr ""

View File

@ -587,6 +587,11 @@ msgstr ""
"Clementine ne može učitati nijednu projektM vizualizaciju. Provjerite da li "
"je Clementine instaliran ispravno."
msgid ""
"Clementine couldn't fetch your subscription status since there are problems "
"with your connection. Played tracks will be cached and sent later to Last.fm."
msgstr ""
msgid "Clementine image viewer"
msgstr "Clementine preglednik slika"
@ -2484,6 +2489,9 @@ msgstr "Sortiranje"
msgid "Speex"
msgstr ""
msgid "Spotify"
msgstr ""
msgid "Standard"
msgstr ""

View File

@ -586,6 +586,11 @@ msgstr ""
"A Clementine egy projectM megjelenítést sem tud betölteni. Ellenőrizze, hogy "
"megfelelően telepítette a Clementinet."
msgid ""
"Clementine couldn't fetch your subscription status since there are problems "
"with your connection. Played tracks will be cached and sent later to Last.fm."
msgstr ""
msgid "Clementine image viewer"
msgstr "Clementine képmegjelenítő"
@ -2490,6 +2495,9 @@ msgstr "Rendezés"
msgid "Speex"
msgstr ""
msgid "Spotify"
msgstr ""
msgid "Standard"
msgstr ""

View File

@ -568,6 +568,11 @@ msgid ""
"installed Clementine properly."
msgstr ""
msgid ""
"Clementine couldn't fetch your subscription status since there are problems "
"with your connection. Played tracks will be cached and sent later to Last.fm."
msgstr ""
msgid "Clementine image viewer"
msgstr ""
@ -2445,6 +2450,9 @@ msgstr ""
msgid "Speex"
msgstr ""
msgid "Spotify"
msgstr ""
msgid "Standard"
msgstr ""

View File

@ -568,6 +568,11 @@ msgid ""
"installed Clementine properly."
msgstr ""
msgid ""
"Clementine couldn't fetch your subscription status since there are problems "
"with your connection. Played tracks will be cached and sent later to Last.fm."
msgstr ""
msgid "Clementine image viewer"
msgstr ""
@ -2445,6 +2450,9 @@ msgstr ""
msgid "Speex"
msgstr ""
msgid "Spotify"
msgstr ""
msgid "Standard"
msgstr ""

View File

@ -591,6 +591,11 @@ msgstr ""
"Clementine non può caricare alcuna visualizzazione projectM. Controlla che "
"Clementine sia installato correttamente."
msgid ""
"Clementine couldn't fetch your subscription status since there are problems "
"with your connection. Played tracks will be cached and sent later to Last.fm."
msgstr ""
msgid "Clementine image viewer"
msgstr "Visualizzatore immagini di Clementine"
@ -2498,6 +2503,9 @@ msgstr "Ordinamento"
msgid "Speex"
msgstr ""
msgid "Spotify"
msgstr ""
msgid "Standard"
msgstr ""

View File

@ -578,6 +578,11 @@ msgstr ""
"Clementine はいかなる projectM の視覚化も読み込むことができませんでした。"
"Clementine が適切にインストールされているかチェックしてください。"
msgid ""
"Clementine couldn't fetch your subscription status since there are problems "
"with your connection. Played tracks will be cached and sent later to Last.fm."
msgstr ""
msgid "Clementine image viewer"
msgstr "Clementine イメージ ビューアー"
@ -2474,6 +2479,9 @@ msgstr "並べ替え"
msgid "Speex"
msgstr ""
msgid "Spotify"
msgstr ""
msgid "Standard"
msgstr ""

View File

@ -568,6 +568,11 @@ msgid ""
"installed Clementine properly."
msgstr ""
msgid ""
"Clementine couldn't fetch your subscription status since there are problems "
"with your connection. Played tracks will be cached and sent later to Last.fm."
msgstr ""
msgid "Clementine image viewer"
msgstr ""
@ -2445,6 +2450,9 @@ msgstr ""
msgid "Speex"
msgstr ""
msgid "Spotify"
msgstr ""
msgid "Standard"
msgstr ""

View File

@ -586,6 +586,11 @@ msgstr ""
"Clementine negalėjo įkelti jokio projectM vaizdinio. Patikrinkite ar "
"tinkamai įdiegėte Clementine."
msgid ""
"Clementine couldn't fetch your subscription status since there are problems "
"with your connection. Played tracks will be cached and sent later to Last.fm."
msgstr ""
msgid "Clementine image viewer"
msgstr "Clementine nuotraukų peržiūros programa"
@ -2484,6 +2489,9 @@ msgstr "Rikiavimas"
msgid "Speex"
msgstr ""
msgid "Spotify"
msgstr ""
msgid "Standard"
msgstr ""

View File

@ -568,6 +568,11 @@ msgid ""
"installed Clementine properly."
msgstr ""
msgid ""
"Clementine couldn't fetch your subscription status since there are problems "
"with your connection. Played tracks will be cached and sent later to Last.fm."
msgstr ""
msgid "Clementine image viewer"
msgstr ""
@ -2445,6 +2450,9 @@ msgstr ""
msgid "Speex"
msgstr ""
msgid "Spotify"
msgstr ""
msgid "Standard"
msgstr ""

View File

@ -568,6 +568,11 @@ msgid ""
"installed Clementine properly."
msgstr ""
msgid ""
"Clementine couldn't fetch your subscription status since there are problems "
"with your connection. Played tracks will be cached and sent later to Last.fm."
msgstr ""
msgid "Clementine image viewer"
msgstr ""
@ -2445,6 +2450,9 @@ msgstr ""
msgid "Speex"
msgstr ""
msgid "Spotify"
msgstr ""
msgid "Standard"
msgstr ""

View File

@ -575,6 +575,11 @@ msgid ""
"installed Clementine properly."
msgstr ""
msgid ""
"Clementine couldn't fetch your subscription status since there are problems "
"with your connection. Played tracks will be cached and sent later to Last.fm."
msgstr ""
msgid "Clementine image viewer"
msgstr ""
@ -2457,6 +2462,9 @@ msgstr ""
msgid "Speex"
msgstr ""
msgid "Spotify"
msgstr ""
msgid "Standard"
msgstr ""

View File

@ -590,6 +590,11 @@ msgstr ""
"Clementine kon geen projectM visualisaties laden. Controleer of u "
"Clementine correct hebt geïnstalleerd."
msgid ""
"Clementine couldn't fetch your subscription status since there are problems "
"with your connection. Played tracks will be cached and sent later to Last.fm."
msgstr ""
msgid "Clementine image viewer"
msgstr "Clementine image viewer"
@ -2495,6 +2500,9 @@ msgstr "Sorteren"
msgid "Speex"
msgstr ""
msgid "Spotify"
msgstr ""
msgid "Standard"
msgstr ""

View File

@ -568,6 +568,11 @@ msgid ""
"installed Clementine properly."
msgstr ""
msgid ""
"Clementine couldn't fetch your subscription status since there are problems "
"with your connection. Played tracks will be cached and sent later to Last.fm."
msgstr ""
msgid "Clementine image viewer"
msgstr ""
@ -2445,6 +2450,9 @@ msgstr ""
msgid "Speex"
msgstr ""
msgid "Spotify"
msgstr ""
msgid "Standard"
msgstr ""

View File

@ -568,6 +568,11 @@ msgid ""
"installed Clementine properly."
msgstr ""
msgid ""
"Clementine couldn't fetch your subscription status since there are problems "
"with your connection. Played tracks will be cached and sent later to Last.fm."
msgstr ""
msgid "Clementine image viewer"
msgstr ""
@ -2445,6 +2450,9 @@ msgstr ""
msgid "Speex"
msgstr ""
msgid "Spotify"
msgstr ""
msgid "Standard"
msgstr ""

View File

@ -586,6 +586,11 @@ msgstr ""
"Clementine nie może wczytać wizualizacji. Sprawdź czy Clementine został "
"zainstalowany prawidłowo."
msgid ""
"Clementine couldn't fetch your subscription status since there are problems "
"with your connection. Played tracks will be cached and sent later to Last.fm."
msgstr ""
msgid "Clementine image viewer"
msgstr "Przeglądarka obrazów Clementine"
@ -2489,6 +2494,9 @@ msgstr "Sortowanie"
msgid "Speex"
msgstr ""
msgid "Spotify"
msgstr ""
msgid "Standard"
msgstr ""

View File

@ -590,6 +590,11 @@ msgstr ""
"O Clementine não conseguiu carregar as visualizações projectM. Verifique se "
"o Clementine foi bem instalado."
msgid ""
"Clementine couldn't fetch your subscription status since there are problems "
"with your connection. Played tracks will be cached and sent later to Last.fm."
msgstr ""
msgid "Clementine image viewer"
msgstr "Visualizador de imagens do Clementine"
@ -2493,6 +2498,9 @@ msgstr "Organização"
msgid "Speex"
msgstr ""
msgid "Spotify"
msgstr ""
msgid "Standard"
msgstr ""

View File

@ -585,6 +585,11 @@ msgstr ""
"O Clementine não conseguiu carregar nenhuma visualização do projectM. "
"Verifique se você instalou o Clementine corretamente."
msgid ""
"Clementine couldn't fetch your subscription status since there are problems "
"with your connection. Played tracks will be cached and sent later to Last.fm."
msgstr ""
msgid "Clementine image viewer"
msgstr "Visualizador de imagens do Clementine"
@ -2491,6 +2496,9 @@ msgstr "Organizando"
msgid "Speex"
msgstr ""
msgid "Spotify"
msgstr ""
msgid "Standard"
msgstr ""

View File

@ -586,6 +586,11 @@ msgstr ""
"Clementine nu a putut încărca nici un projectM vizualizări. Verificaţi dacă "
"aţi instalat corect Clementine."
msgid ""
"Clementine couldn't fetch your subscription status since there are problems "
"with your connection. Played tracks will be cached and sent later to Last.fm."
msgstr ""
msgid "Clementine image viewer"
msgstr "Vizualizator de imagini Clementine"
@ -2484,6 +2489,9 @@ msgstr ""
msgid "Speex"
msgstr ""
msgid "Spotify"
msgstr ""
msgid "Standard"
msgstr ""

View File

@ -584,6 +584,11 @@ msgstr ""
"Clementine не может загрузить какою-либо визуализацию projectM. Проверьте, "
"что установили Clementine правильно."
msgid ""
"Clementine couldn't fetch your subscription status since there are problems "
"with your connection. Played tracks will be cached and sent later to Last.fm."
msgstr ""
msgid "Clementine image viewer"
msgstr "Просмотр изображений в Clementine"
@ -2484,6 +2489,9 @@ msgstr "Сортировать"
msgid "Speex"
msgstr ""
msgid "Spotify"
msgstr ""
msgid "Standard"
msgstr ""

View File

@ -583,6 +583,11 @@ msgstr ""
"Clementine nemôže načítať žiadnu projectM vizualizáciu. Skontrolujte, či "
"máte Clementine nainštalovaný správne."
msgid ""
"Clementine couldn't fetch your subscription status since there are problems "
"with your connection. Played tracks will be cached and sent later to Last.fm."
msgstr ""
msgid "Clementine image viewer"
msgstr "Clementine prehliadač obrázkov"
@ -2480,6 +2485,9 @@ msgstr "Triedenie"
msgid "Speex"
msgstr ""
msgid "Spotify"
msgstr ""
msgid "Standard"
msgstr ""

View File

@ -585,6 +585,11 @@ msgstr ""
"Clementine ni mogel naložiti predočenj projectM. Preverite, če je Clementine "
"pravilno nameščen."
msgid ""
"Clementine couldn't fetch your subscription status since there are problems "
"with your connection. Played tracks will be cached and sent later to Last.fm."
msgstr ""
msgid "Clementine image viewer"
msgstr "Pregledovalnik datotek Clementine"
@ -2485,6 +2490,9 @@ msgstr "Razvrščanje"
msgid "Speex"
msgstr ""
msgid "Spotify"
msgstr ""
msgid "Standard"
msgstr ""

View File

@ -570,6 +570,11 @@ msgstr ""
"Клементина не може учитати пројекатМ визуализацију. Проверите да ли сте "
"правилно инсталирали Клементину."
msgid ""
"Clementine couldn't fetch your subscription status since there are problems "
"with your connection. Played tracks will be cached and sent later to Last.fm."
msgstr ""
msgid "Clementine image viewer"
msgstr ""
@ -2453,6 +2458,9 @@ msgstr ""
msgid "Speex"
msgstr ""
msgid "Spotify"
msgstr ""
msgid "Standard"
msgstr ""

View File

@ -587,6 +587,11 @@ msgstr ""
"Clementine kunde inte läsa in några projectM-visualiseringar. Kontrollera "
"att du har installerat Clementine ordentligt."
msgid ""
"Clementine couldn't fetch your subscription status since there are problems "
"with your connection. Played tracks will be cached and sent later to Last.fm."
msgstr ""
msgid "Clementine image viewer"
msgstr "Clementine-bildvisare"
@ -2483,6 +2488,9 @@ msgstr "Sortering"
msgid "Speex"
msgstr ""
msgid "Spotify"
msgstr ""
msgid "Standard"
msgstr ""

View File

@ -582,6 +582,11 @@ msgstr ""
"Clementine projectM görsellerini yükleyemedi. Clementine programını düzgün "
"yüklediğinizi kontrol edin."
msgid ""
"Clementine couldn't fetch your subscription status since there are problems "
"with your connection. Played tracks will be cached and sent later to Last.fm."
msgstr ""
msgid "Clementine image viewer"
msgstr "Clementine resim görüntüleyici"
@ -2482,6 +2487,9 @@ msgstr "Dizim"
msgid "Speex"
msgstr ""
msgid "Spotify"
msgstr ""
msgid "Standard"
msgstr ""

View File

@ -558,6 +558,11 @@ msgid ""
"installed Clementine properly."
msgstr ""
msgid ""
"Clementine couldn't fetch your subscription status since there are problems "
"with your connection. Played tracks will be cached and sent later to Last.fm."
msgstr ""
msgid "Clementine image viewer"
msgstr ""
@ -2435,6 +2440,9 @@ msgstr ""
msgid "Speex"
msgstr ""
msgid "Spotify"
msgstr ""
msgid "Standard"
msgstr ""

View File

@ -585,6 +585,11 @@ msgstr ""
"Clementine не вдалось завантажити візуалізації projectM. Перевірте чи ви "
"правильно встановили Clementine."
msgid ""
"Clementine couldn't fetch your subscription status since there are problems "
"with your connection. Played tracks will be cached and sent later to Last.fm."
msgstr ""
msgid "Clementine image viewer"
msgstr "Переглядач зображень Clementine"
@ -2481,6 +2486,9 @@ msgstr "Сортування"
msgid "Speex"
msgstr ""
msgid "Spotify"
msgstr ""
msgid "Standard"
msgstr ""

View File

@ -583,6 +583,11 @@ msgstr ""
"Clementine không thể nạp hiệu ứng hình ảnh ảo projectM. XIn chắc rằng bạn đã "
"cài đặt Clementine đúng cách."
msgid ""
"Clementine couldn't fetch your subscription status since there are problems "
"with your connection. Played tracks will be cached and sent later to Last.fm."
msgstr ""
msgid "Clementine image viewer"
msgstr "Bộ xem ảnh Clementine"
@ -2485,6 +2490,9 @@ msgstr "Sắp xếp"
msgid "Speex"
msgstr ""
msgid "Spotify"
msgstr ""
msgid "Standard"
msgstr ""

View File

@ -570,6 +570,11 @@ msgid ""
"installed Clementine properly."
msgstr ""
msgid ""
"Clementine couldn't fetch your subscription status since there are problems "
"with your connection. Played tracks will be cached and sent later to Last.fm."
msgstr ""
msgid "Clementine image viewer"
msgstr "Clementine 图像查看器"
@ -2447,6 +2452,9 @@ msgstr "正在排序"
msgid "Speex"
msgstr ""
msgid "Spotify"
msgstr ""
msgid "Standard"
msgstr ""

View File

@ -572,6 +572,11 @@ msgid ""
"installed Clementine properly."
msgstr ""
msgid ""
"Clementine couldn't fetch your subscription status since there are problems "
"with your connection. Played tracks will be cached and sent later to Last.fm."
msgstr ""
msgid "Clementine image viewer"
msgstr ""
@ -2449,6 +2454,9 @@ msgstr ""
msgid "Speex"
msgstr ""
msgid "Spotify"
msgstr ""
msgid "Standard"
msgstr ""

View File

@ -898,8 +898,9 @@ void MainWindow::SongChanged(const Song& song) {
void MainWindow::TrackSkipped(PlaylistItemPtr item) {
// If it was a library item then we have to increment its skipped count in
// the database.
if (item && item->IsLocalLibraryItem() &&
item->Metadata().id() != -1 && playlists_->active()->get_lastfm_status() != Playlist::LastFM_Scrobbled) {
if (item && item->IsLocalLibraryItem() && item->Metadata().id() != -1 &&
playlists_->active()->get_lastfm_status() != Playlist::LastFM_Scrobbled &&
playlists_->active()->get_lastfm_status() != Playlist::LastFM_Queued) {
Song song = item->Metadata();
const qint64 position = player_->engine()->position_nanosec();
const qint64 length = player_->engine()->length_nanosec();
@ -1083,7 +1084,7 @@ void MainWindow::UpdateTrackPosition() {
if (position >= scrobble_point) {
if (playlist->get_lastfm_status() == Playlist::LastFM_New) {
#ifdef HAVE_LIBLASTFM
if (lastfm_service->IsScrobblingEnabled()) {
if (lastfm_service->IsScrobblingEnabled() && lastfm_service->IsAuthenticated()) {
qLog(Info) << "Scrobbling at" << scrobble_point;
lastfm_service->Scrobble();
}
@ -2186,6 +2187,12 @@ void MainWindow::ScrobblerStatus(int value) {
ui_->action_toggle_scrobbling->setIcon(QIcon(":/last.fm/as.png"));
break;
case 30:
// Hack: when offline, liblastfm doesn't inform us, so set the status
// as queued; in this way we won't try to scrobble again, it will be done automatically
playlists_->active()->set_lastfm_status(Playlist::LastFM_Queued);
break;
default:
if (value > 3) {
// we're for sure in an error state