mirror of
https://github.com/vcmi/vcmi.git
synced 2025-11-23 22:37:55 +02:00
Minor improvements & fixes to music player
- music will be selected correctly after rapid leaving and reentering town screen - music sets are now store as single std::map instead of unnecessary "map of maps" - fixed computation of resume time for restarted/looped music tracks - updated & clarified some comments - converted C functions for SDL_Mixer callbacks into lambdas - formatting fixes
This commit is contained in:
@@ -170,6 +170,8 @@ class VCMIDirsWIN32 final : public IVCMIDirs
|
||||
|
||||
void VCMIDirsWIN32::init()
|
||||
{
|
||||
std::locale::global(boost::locale::generator().generate("en_US.UTF-8"));
|
||||
|
||||
// Call base (init dirs)
|
||||
IVCMIDirs::init();
|
||||
|
||||
@@ -698,11 +700,6 @@ namespace VCMIDirs
|
||||
static bool initialized = false;
|
||||
if (!initialized)
|
||||
{
|
||||
#ifdef VCMI_WINDOWS
|
||||
std::locale::global(boost::locale::generator().generate("en_US.UTF-8"));
|
||||
#endif
|
||||
boost::filesystem::path::imbue(std::locale());
|
||||
|
||||
singleton.init();
|
||||
initialized = true;
|
||||
}
|
||||
@@ -710,5 +707,4 @@ namespace VCMIDirs
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
VCMI_LIB_NAMESPACE_END
|
||||
|
||||
Reference in New Issue
Block a user