We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 1fa00fa commit 0043929Copy full SHA for 0043929
1 file changed
KeyboardVisualizerCommon/Visualizer.cpp
@@ -308,18 +308,8 @@ void Visualizer::SaveSettings()
308
silent_bkgd = FALSE;
309
}
310
311
- //Get file path in executable directory
312
-//#ifdef WIN32
313
-// GetModuleFileName(NULL, filename, 2048);
314
-// strcpy(filename, std::string(filename).substr(0, std::string(filename).find_last_of("\\/")).c_str());
315
-// strcat(filename, "\\settings.txt");
316
-//#else
317
-// char arg1[64];
318
-// snprintf(arg1, 64, "/proc/%d/exe", getpid());
319
-// readlink(arg1, filename, 1024);
320
321
-// strcat(filename, "/settings.txt");
322
-//#endif
+ //Set filename
+ strcpy(filename, "settings.txt");
323
324
//Open settings file
325
outfile.open(filename);
0 commit comments