Include OSX 10.12 name and branding in wxGetOsDescription()
Starting with 10.12 OSX will be renamed to macOS. The name for version 10.12 is Sierra. Closes https://github.com/wxWidgets/wxWidgets/pull/297
This commit is contained in:
committed by
Vadim Zeitlin
parent
ce4070fc16
commit
ac5a362d8d
@@ -114,6 +114,7 @@ wxOSX:
|
|||||||
- Turn off automatic quotes substitutions in wxTextCtrl (Xlord2).
|
- Turn off automatic quotes substitutions in wxTextCtrl (Xlord2).
|
||||||
- Implement wxDataViewChoiceByIndexRenderer (wanup).
|
- Implement wxDataViewChoiceByIndexRenderer (wanup).
|
||||||
- Fix unnecessary indentation in list-like wxDataViewCtrl (Andreas Falkenhahn).
|
- Fix unnecessary indentation in list-like wxDataViewCtrl (Andreas Falkenhahn).
|
||||||
|
- Recognize macOS 10.12 Sierra in wxGetOsDescription() (Tobias Taschner).
|
||||||
|
|
||||||
Unix:
|
Unix:
|
||||||
|
|
||||||
|
@@ -109,7 +109,8 @@ wxString wxGetOsDescription()
|
|||||||
// Notice that neither the OS name itself nor the code names seem to be
|
// Notice that neither the OS name itself nor the code names seem to be
|
||||||
// ever translated, OS X itself uses the English words even for the
|
// ever translated, OS X itself uses the English words even for the
|
||||||
// languages not using Roman alphabet.
|
// languages not using Roman alphabet.
|
||||||
wxString osBrand = "OS X";
|
// Starting with 10.12 the macOS branding is used
|
||||||
|
wxString osBrand = wxCheckOsVersion(10, 12) ? "macOS" : "OS X";
|
||||||
wxString osName;
|
wxString osName;
|
||||||
if (majorVer == 10)
|
if (majorVer == 10)
|
||||||
{
|
{
|
||||||
@@ -132,6 +133,9 @@ wxString wxGetOsDescription()
|
|||||||
case 11:
|
case 11:
|
||||||
osName = "El Capitan";
|
osName = "El Capitan";
|
||||||
break;
|
break;
|
||||||
|
case 12:
|
||||||
|
osName = "Sierra";
|
||||||
|
break;
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
#else
|
#else
|
||||||
|
Reference in New Issue
Block a user