Move love.system.getTheme() to love.window.getSystemTheme().

Despite its name, `SDL_GetSystemTheme()` needs the video subsystem to properly function. So, put it in love.window instead.
This commit is contained in:
Miku AuahDark
2025-11-25 15:29:24 +08:00
parent 139a45bfae
commit c4d30081f4
10 changed files with 60 additions and 64 deletions
+9
View File
@@ -112,5 +112,14 @@ STRINGMAP_CLASS_BEGIN(Window, Window::DisplayOrientation, Window::ORIENTATION_MA
}
STRINGMAP_CLASS_END(Window, Window::DisplayOrientation, Window::ORIENTATION_MAX_ENUM, orientation)
STRINGMAP_CLASS_BEGIN(Window, Window::SystemTheme, Window::THEME_MAX_ENUM, systemThemes)
{
{"unknown", Window::THEME_UNKNOWN},
{"light", Window::THEME_LIGHT},
{"dark", Window::THEME_DARK}
};
STRINGMAP_CLASS_END(Window, Window::SystemTheme, Window::THEME_MAX_ENUM, systemThemes)
} // window
} // love