Refactor AudioEngine, fix compile issue.

This commit is contained in:
halx99 2019-11-24 15:07:48 +08:00
parent a759332591
commit c8f85a4a95
2 changed files with 2 additions and 2 deletions

View File

@ -338,7 +338,7 @@ void AudioEngine::remove(AUDIO_ID audioID)
if (it->second.profileHelper) {
it->second.profileHelper->audioIDs.remove(audioID);
}
_audioPathIDMap[*it->second.filePath].remove(audioID);
_audioPathIDMap[it->second.filePath].remove(audioID);
_audioIDInfoMap.erase(audioID);
}
}

View File

@ -416,7 +416,7 @@ void AudioEngineImpl::update(float dt)
std::string filePath;
if (player->_finishCallbak) {
auto& audioInfo = AudioEngine::_audioIDInfoMap[audioID];
filePath = *audioInfo.filePath;
filePath = audioInfo.filePath;
}
AudioEngine::remove(audioID);