~aleteoryx/muditaos

6cac30cb1c96684378ebd5a7b331bafd4b4be616 — tomaszkrosnowski 4 years ago 7ac0c1d
[EGD-7848] Fix MP behavior

When track is finished and track progress bar is shown it now will be
replaced with empty track screen.
M module-apps/application-music-player/models/SongsModel.cpp => module-apps/application-music-player/models/SongsModel.cpp +0 -1
@@ 64,7 64,6 @@ namespace app::music_player
        }

        item->activatedCallback = [this, song](gui::Item &) {
            LOG_ERROR("activatedCallback for %s", song->fileInfo.path.c_str());
            if (shortReleaseCallback != nullptr) {
                activatedRecord = *song;
                shortReleaseCallback(song->fileInfo.path);

M module-apps/application-music-player/windows/MusicPlayerMainWindow.cpp => module-apps/application-music-player/windows/MusicPlayerMainWindow.cpp +7 -0
@@ 387,11 387,18 @@ namespace gui
                currentArtist = utils::translate("app_music_player_uknown_artist");

            currentTotalTime = record->audioProperties.songLength;
            if (myViewMode == ViewMode::START) {
                changeCurrentMode(ViewMode::TRACK);
            }
        }
        else {
            currentTitle     = "";
            currentArtist    = "";
            currentTotalTime = 0;

            if (myViewMode == ViewMode::TRACK) {
                changeCurrentMode(ViewMode::START);
            }
        }

        updateVisibleTrackData(state);