SettingsLocationType readType;
SettingsLocationType writeType;
+#if !defined(__EMSCRIPTEN__)
FileMonitor settingsMonitor
{
this, fileChange = { modified = true };
return true;
}
};
+#endif
File f;
bool locked;
SettingsLocationType type = readType;
if(!f)
{
+#if !defined(__EMSCRIPTEN__)
settingsMonitor.StopMonitoring();
+#endif
if(settingsFilePath)
FileOpenTryRead(type);
{
locked = false;
+#if !defined(__EMSCRIPTEN__)
settingsMonitor.StopMonitoring();
+#endif
if(settingsFilePath)
// Don't auto delete settingsFilePath because only want to try another path if we were using a global path
{
if(f)
{
+#if !defined(__EMSCRIPTEN__)
settingsMonitor.StopMonitoring();
+#endif
f.Unlock(0,0,true);
locked = false;
delete f;
Close();
if(settingsFilePath && OnAskReloadSettings != GlobalSettings::OnAskReloadSettings)
{
+#if !defined(__EMSCRIPTEN__)
settingsMonitor.fileName = settingsFilePath;
settingsMonitor.StartMonitoring();
+#endif
}
}
}