Review Request 110934: Adds a Offline Mode to Amarok i.e. fixes Bug 229111
Mark Kretschmann
kretschmann at kde.org
Tue Jul 2 10:29:33 UTC 2013
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
http://git.reviewboard.kde.org/r/110934/
-----------------------------------------------------------
(Updated July 2, 2013, 10:29 a.m.)
Status
------
This change has been discarded.
Review request for Amarok.
Description
-------
Adds a "Offline Mode" to the "Amarok" menu. In Offline Mode, The::networkAccessManager()->getData(...) returns NULL, and prints a error() message.
Also, I have updated existing code so that it checks whether Amarok is in Offline Mode before placing the getData request.
However, this is not a fail safe mechanism. Newer codes can use the QNetworkAccessManager::get(...) direcrtly or make use of the The::networkAccessManager in other ways. Scripts cannot do this since its methods check first but this too can be changed. So, care still has to be taken while writing newer code. I have mentioned the same as comments in the code.
This addresses bug 229111.
https://bugs.kde.org/show_bug.cgi?id=229111
Diffs
-----
src/ActionClasses.h 0187402
src/ActionClasses.h 0187402
src/ActionClasses.h 0187402
src/ActionClasses.cpp cce6f20
src/ActionClasses.cpp cce6f20
src/ActionClasses.cpp cce6f20
src/MainWindow.cpp af47db7
src/MainWindow.cpp af47db7
src/MainWindow.cpp af47db7
src/amarokconfig.kcfg e00325d
src/amarokconfig.kcfg e00325d
src/amarokconfig.kcfg e00325d
src/context/applets/photos/PhotosScrollWidget.cpp b5e872a
src/context/applets/photos/PhotosScrollWidget.cpp b5e872a
src/context/applets/similarartists/ArtistWidget.cpp 511f641
src/context/applets/similarartists/ArtistWidget.cpp 511f641
src/context/applets/upcomingevents/UpcomingEventsApplet.cpp 38742df
src/context/applets/upcomingevents/UpcomingEventsApplet.cpp 38742df
src/context/applets/upcomingevents/UpcomingEventsMapWidget.h 99e55b2
src/context/applets/upcomingevents/UpcomingEventsMapWidget.h 99e55b2
src/context/applets/upcomingevents/UpcomingEventsMapWidget.cpp 9c11506
src/context/applets/upcomingevents/UpcomingEventsMapWidget.cpp 9c11506
src/context/applets/upcomingevents/UpcomingEventsWidget.cpp 323ec1e
src/context/applets/upcomingevents/UpcomingEventsWidget.cpp 323ec1e
src/context/applets/wikipedia/WikipediaApplet.cpp 0f7a3b0
src/context/applets/wikipedia/WikipediaApplet.cpp 0f7a3b0
src/context/engines/labels/LabelsEngine.cpp ad3ae71
src/context/engines/labels/LabelsEngine.cpp ad3ae71
src/context/engines/photos/PhotosEngine.cpp f9f8fd5
src/context/engines/photos/PhotosEngine.cpp f9f8fd5
src/context/engines/similarartists/SimilarArtistsEngine.cpp 898beb4
src/context/engines/similarartists/SimilarArtistsEngine.cpp 898beb4
src/context/engines/tabs/TabsEngine.cpp 24a89df
src/context/engines/tabs/TabsEngine.cpp 24a89df
src/context/engines/upcomingevents/UpcomingEventsEngine.cpp b869a3c
src/context/engines/upcomingevents/UpcomingEventsEngine.cpp b869a3c
src/context/engines/wikipedia/WikipediaEngine.cpp 0b75f15
src/context/engines/wikipedia/WikipediaEngine.cpp 0b75f15
src/context/widgets/DropPixmapItem.cpp 62b0e90
src/context/widgets/DropPixmapItem.cpp 62b0e90
src/covermanager/CoverFetcher.cpp 3cf32cc
src/covermanager/CoverFetcher.cpp 3cf32cc
src/covermanager/CoverFoundDialog.cpp 6d7efa2
src/covermanager/CoverFoundDialog.cpp 6d7efa2
src/musicbrainz/MusicBrainzFinder.cpp 6892232
src/musicbrainz/MusicBrainzFinder.cpp 6892232
src/musicbrainz/MusicDNSFinder.cpp d393211
src/musicbrainz/MusicDNSFinder.cpp d393211
src/network/NetworkAccessManagerProxy.h 6285f0f
src/network/NetworkAccessManagerProxy.h 6285f0f
src/network/NetworkAccessManagerProxy.h 6285f0f
src/network/NetworkAccessManagerProxy.cpp a2694bf
src/network/NetworkAccessManagerProxy.cpp a2694bf
src/network/NetworkAccessManagerProxy.cpp a2694bf
src/scriptengine/AmarokNetworkScript.cpp 0eaa440
src/scriptengine/AmarokNetworkScript.cpp 0eaa440
src/services/ampache/AmpacheAccountLogin.cpp 26aebed
src/services/ampache/AmpacheAccountLogin.cpp 26aebed
src/services/ampache/AmpacheServiceCollection.cpp 140c465
src/services/ampache/AmpacheServiceCollection.cpp 140c465
src/services/ampache/AmpacheServiceQueryMaker.cpp b94c3b0
src/services/ampache/AmpacheServiceQueryMaker.cpp b94c3b0
src/services/lastfm/AvatarDownloader.cpp b54b252
src/services/lastfm/AvatarDownloader.cpp b54b252
src/services/lastfm/LastFmService.cpp 4c100c4
src/services/lastfm/LastFmService.cpp 4c100c4
src/services/lastfm/LastFmServiceSettings.h 82b9b00
src/services/lastfm/LastFmServiceSettings.h 82b9b00
src/services/lastfm/LastFmServiceSettings.cpp 086997e
src/services/lastfm/LastFmServiceSettings.cpp 086997e
Diff: http://git.reviewboard.kde.org/r/110934/diff/
Testing
-------
Testing done. Builds and runs. I even made sure error messages were being shown (and no other undesired effects, like a crash, were taking place) if The::networkAccessManager()->getData(...) was called inappropriately.
Thanks,
Vedant Agarwala
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/amarok-devel/attachments/20130702/fb64b7bd/attachment.html>
More information about the Amarok-devel
mailing list