Four-space indents, braces on their own lines, and one-statement bodies without braces. Semicolons in comments became full stops. Designated initializers may leave fields out without a warning.
17 lines
335 B
C++
17 lines
335 B
C++
#include "sdl.h"
|
|
|
|
#include <SDL3/SDL_filesystem.h>
|
|
#include <SDL3/SDL_stdinc.h>
|
|
|
|
#include "path.h"
|
|
|
|
std::filesystem::path preferences_directory_get()
|
|
{
|
|
auto sdlPath = SDL_GetPrefPath(nullptr, "anm2ed");
|
|
if (!sdlPath)
|
|
return {};
|
|
auto filePath = path_from_utf8(sdlPath);
|
|
SDL_free(sdlPath);
|
|
return filePath;
|
|
}
|