diff options
author | Lars Knoll <lars.knoll@nokia.com> | 2012-04-16 12:04:34 +0200 |
---|---|---|
committer | Lars Knoll <lars.knoll@nokia.com> | 2012-04-16 12:04:34 +0200 |
commit | 9bd032355163d92cda5e7e59ecd21214b131f187 (patch) | |
tree | 002fa12558505683143c7eb08949a3d225bf0712 /src/corelib/global/qglobal.cpp | |
parent | d037d25c3d5236623371cf051aaf6a9e59792ba7 (diff) | |
parent | 41673c45dde2eb95ee21dd918235218399f2be2c (diff) |
Merge remote-tracking branch 'origin/master' into api_changes
Conflicts:
configure
src/corelib/io/qurl.cpp
src/gui/kernel/qwindow.cpp
src/tools/moc/generator.cpp
src/widgets/kernel/qwidget_qpa.cpp
src/widgets/styles/qstyle.h
src/widgets/widgets/qtabbar.cpp
tests/auto/corelib/codecs/utf8/tst_utf8.cpp
Change-Id: Ia457228d6f684ec8184e13e8fcc9d25857b1751e
Diffstat (limited to 'src/corelib/global/qglobal.cpp')
-rw-r--r-- | src/corelib/global/qglobal.cpp | 13 |
1 files changed, 12 insertions, 1 deletions
diff --git a/src/corelib/global/qglobal.cpp b/src/corelib/global/qglobal.cpp index 51849d701a..74c65d2504 100644 --- a/src/corelib/global/qglobal.cpp +++ b/src/corelib/global/qglobal.cpp @@ -1711,6 +1711,8 @@ QSysInfo::WinVersion QSysInfo::windowsVersion() winver = QSysInfo::WV_VISTA; } else if (osver.dwMajorVersion == 6 && osver.dwMinorVersion == 1) { winver = QSysInfo::WV_WINDOWS7; + } else if (osver.dwMajorVersion == 6 && osver.dwMinorVersion == 2) { + winver = QSysInfo::WV_WINDOWS8; } else { qWarning("Qt: Untested Windows version %d.%d detected!", int(osver.dwMajorVersion), int(osver.dwMinorVersion)); @@ -1742,6 +1744,8 @@ QSysInfo::WinVersion QSysInfo::windowsVersion() winver = QSysInfo::WV_VISTA; else if (override == "WINDOWS7") winver = QSysInfo::WV_WINDOWS7; + else if (override == "WINDOWS8") + winver = QSysInfo::WV_WINDOWS8; } #endif @@ -2511,7 +2515,9 @@ int qrand() \list \li \c Q_PRIMITIVE_TYPE specifies that \a Type is a POD (plain old - data) type with no constructor or destructor. + data) type with no constructor or destructor, or else a type where + every bit pattern is a valid object and memcpy() creates a valid + independent copy of the object. \li \c Q_MOVABLE_TYPE specifies that \a Type has a constructor and/or a destructor but can be moved in memory using \c memcpy(). @@ -2524,6 +2530,11 @@ int qrand() \snippet doc/src/snippets/code/src_corelib_global_qglobal.cpp 38 + An example of a non-POD "primitive" type is QUuid: Even though + QUuid has constructors (and therefore isn't POD), every bit + pattern still represents a valid object, and memcpy() can be used + to create a valid independent copy of a QUuid object. + Example of a movable type: \snippet doc/src/snippets/code/src_corelib_global_qglobal.cpp 39 |