You've already forked godot
mirror of
https://github.com/godotengine/godot.git
synced 2025-11-04 12:00:25 +00:00
Add OS.get_version_alias() to return a human-readable Windows/macOS version number
Windows 11's major version number is actually 10.x.x, which can be confusing if you don't know about this quirk. `OS.get_version_alias()` avoids this by displaying the "branding" version number and the build number as a suffix, so that individual updates can still be distinguished from each other. On macOS, `OS.get_version_alias()` returns the version number prepended with the version name (e.g. Sequoia for macOS 15). On other operating systems, this returns the same value as `OS.get_version()`.
This commit is contained in:
@@ -167,7 +167,7 @@ typedef bool(WINAPI *ShouldAppsUseDarkModePtr)();
|
||||
typedef DWORD(WINAPI *GetImmersiveColorFromColorSetExPtr)(UINT dwImmersiveColorSet, UINT dwImmersiveColorType, bool bIgnoreHighContrast, UINT dwHighContrastCacheMode);
|
||||
typedef int(WINAPI *GetImmersiveColorTypeFromNamePtr)(const WCHAR *name);
|
||||
typedef int(WINAPI *GetImmersiveUserColorSetPreferencePtr)(bool bForceCheckRegistry, bool bSkipCheckOnFail);
|
||||
typedef HRESULT(WINAPI *RtlGetVersionPtr)(OSVERSIONINFOW *lpVersionInformation);
|
||||
typedef HRESULT(WINAPI *RtlGetVersionPtr)(OSVERSIONINFOEXW *lpVersionInformation);
|
||||
typedef bool(WINAPI *AllowDarkModeForAppPtr)(bool darkMode);
|
||||
typedef PreferredAppMode(WINAPI *SetPreferredAppModePtr)(PreferredAppMode appMode);
|
||||
typedef void(WINAPI *RefreshImmersiveColorPolicyStatePtr)();
|
||||
@@ -419,7 +419,7 @@ class DisplayServerWindows : public DisplayServer {
|
||||
TIMER_ID_WINDOW_ACTIVATION = 2,
|
||||
};
|
||||
|
||||
OSVERSIONINFOW os_ver;
|
||||
OSVERSIONINFOEXW os_ver;
|
||||
|
||||
enum {
|
||||
KEY_EVENT_BUFFER_SIZE = 512
|
||||
|
||||
Reference in New Issue
Block a user