Use system config path for config
This commit is contained in:
@@ -812,12 +812,6 @@ int main(int argc, char **argv)
|
||||
WorkDir = GetWorkingDir(Perm);
|
||||
{
|
||||
String sdl_config_path = SDL_GetPrefPath("krzosa", "text_editor");
|
||||
if (sdl_config_path.len && sdl_config_path.data[sdl_config_path.len - 1] == '\\') {
|
||||
sdl_config_path = Chop(sdl_config_path, 1); // chop '/'
|
||||
}
|
||||
if (sdl_config_path.len && sdl_config_path.data[sdl_config_path.len - 1] == '/') {
|
||||
sdl_config_path = Chop(sdl_config_path, 1); // chop '/'
|
||||
}
|
||||
ConfigDir = NormalizePath(Perm, sdl_config_path);
|
||||
SDL_free(sdl_config_path.data);
|
||||
}
|
||||
@@ -902,7 +896,7 @@ int main(int argc, char **argv)
|
||||
}
|
||||
|
||||
Scratch scratch;
|
||||
GlobalConfigBufferID = LoadConfig(Format(scratch, "%S/config.te", GetExeDir(scratch)));
|
||||
GlobalConfigBufferID = LoadConfig(Format(scratch, "%S/config.te", ConfigDir));
|
||||
for (int i = 1; i < argc; i += 1) {
|
||||
String it = argv[i];
|
||||
if (EndsWith(it, ".te")) {
|
||||
|
||||
Reference in New Issue
Block a user