diff options
author | Friedemann Kleint <Friedemann.Kleint@qt.io> | 2018-03-05 09:10:24 +0100 |
---|---|---|
committer | Friedemann Kleint <Friedemann.Kleint@qt.io> | 2018-03-05 12:56:41 +0100 |
commit | f3139399b273fdf405f20cba32a08262cd933d6e (patch) | |
tree | deed895170c12f8478af44a73b23b63b75239957 /sources/pyside2/PySide2 | |
parent | 2b94776295e1d9f882096b4f2c7ca0a93a20b20c (diff) | |
parent | b57c557c8cd1012851f8a245075591dc33be425b (diff) |
Merge remote-tracking branch 'origin/5.6' into 5.9
Change-Id: I452d3a0a04e282b678879132ca1b3a272910ef04
Diffstat (limited to 'sources/pyside2/PySide2')
-rw-r--r-- | sources/pyside2/PySide2/CMakeLists.txt | 5 | ||||
-rw-r--r-- | sources/pyside2/PySide2/QtGui/typesystem_gui_common.xml | 3 | ||||
-rw-r--r-- | sources/pyside2/PySide2/__init__.py.in | 7 | ||||
-rw-r--r-- | sources/pyside2/PySide2/_config.py.in | 11 | ||||
-rw-r--r-- | sources/pyside2/PySide2/typesystem_templates.xml | 6 |
5 files changed, 30 insertions, 2 deletions
diff --git a/sources/pyside2/PySide2/CMakeLists.txt b/sources/pyside2/PySide2/CMakeLists.txt index 21db337e9..971d0a9ef 100644 --- a/sources/pyside2/PySide2/CMakeLists.txt +++ b/sources/pyside2/PySide2/CMakeLists.txt @@ -10,6 +10,9 @@ configure_file("${CMAKE_CURRENT_SOURCE_DIR}/__init__.py.in" configure_file("${CMAKE_CURRENT_SOURCE_DIR}/_config.py.in" "${CMAKE_CURRENT_BINARY_DIR}/_config.py" @ONLY) +configure_file("${CMAKE_CURRENT_SOURCE_DIR}/../pyside_version.py" + "${CMAKE_CURRENT_BINARY_DIR}/_git_pyside_version.py" @ONLY) + configure_file("${CMAKE_CURRENT_SOURCE_DIR}/support/__init__.py" "${CMAKE_CURRENT_BINARY_DIR}/support/__init__.py" COPYONLY) configure_file("${CMAKE_CURRENT_SOURCE_DIR}/support/signature/__init__.py" @@ -69,6 +72,8 @@ install(FILES "${CMAKE_CURRENT_BINARY_DIR}/__init__.py" DESTINATION "${PYTHON_SITE_PACKAGES}/${BINDING_NAME}${pyside2_SUFFIX}") install(FILES "${CMAKE_CURRENT_BINARY_DIR}/_config.py" DESTINATION "${PYTHON_SITE_PACKAGES}/${BINDING_NAME}${pyside2_SUFFIX}") +install(FILES "${CMAKE_CURRENT_BINARY_DIR}/_git_pyside_version.py" + DESTINATION "${PYTHON_SITE_PACKAGES}/${BINDING_NAME}${pyside2_SUFFIX}") install(FILES ${CMAKE_CURRENT_SOURCE_DIR}/typesystem_templates.xml DESTINATION share/PySide2${pyside_SUFFIX}/typesystems) install(FILES ${CMAKE_CURRENT_BINARY_DIR}/pyside2_global.h diff --git a/sources/pyside2/PySide2/QtGui/typesystem_gui_common.xml b/sources/pyside2/PySide2/QtGui/typesystem_gui_common.xml index 12b0f3115..0f6d48968 100644 --- a/sources/pyside2/PySide2/QtGui/typesystem_gui_common.xml +++ b/sources/pyside2/PySide2/QtGui/typesystem_gui_common.xml @@ -1731,6 +1731,9 @@ <modify-argument index="return"> <replace-type modified-type="QString"/> </modify-argument> + <inject-code class="native" position="end"> + <insert-template name="return_QString_native"/> + </inject-code> <inject-code class="target" position="end"> <insert-template name="return_QString"/> </inject-code> diff --git a/sources/pyside2/PySide2/__init__.py.in b/sources/pyside2/PySide2/__init__.py.in index 92e52a81a..4ce266b69 100644 --- a/sources/pyside2/PySide2/__init__.py.in +++ b/sources/pyside2/PySide2/__init__.py.in @@ -1,14 +1,17 @@ __all__ = list("Qt" + body for body in "@all_module_shortnames@" .split(";")) -__version__ = "@BINDING_API_VERSION_FULL@" -__version_info__ = (@BINDING_API_MAJOR_VERSION@, @BINDING_API_MINOR_VERSION@, @BINDING_API_MICRO_VERSION@, "@BINDING_API_RELEASE_LEVEL@", @BINDING_API_SERIAL@) +__version__ = "@FINAL_PACKAGE_VERSION@" +__version_info__ = (@BINDING_API_MAJOR_VERSION@, @BINDING_API_MINOR_VERSION@, @BINDING_API_MICRO_VERSION@, "@BINDING_API_PRE_RELEASE_VERSION_TYPE@", @BINDING_API_PRE_RELEASE_VERSION@) @PYSIDE_BUILD_DATE@ @PYSIDE_BUILD_COMMIT_DATE@ @PYSIDE_BUILD_COMMIT_HASH@ @PYSIDE_BUILD_COMMIT_HASH_DESCRIBED@ +# Timestamp used for snapshot build, which is part of snapshot package version. +@PYSIDE_SETUP_PY_PACKAGE_TIMESTAMP_ASSIGNMENT@ + def _setupQtDirectories(): import sys import os diff --git a/sources/pyside2/PySide2/_config.py.in b/sources/pyside2/PySide2/_config.py.in index db8a17210..6f8d022dc 100644 --- a/sources/pyside2/PySide2/_config.py.in +++ b/sources/pyside2/PySide2/_config.py.in @@ -4,3 +4,14 @@ built_modules = list(name for name in shiboken_library_soversion = str(@SHIBOKEN_SO_VERSION@) pyside_library_soversion = str(@PYSIDE_SO_VERSION@) + +version = "@FINAL_PACKAGE_VERSION@" +version_info = (@BINDING_API_MAJOR_VERSION@, @BINDING_API_MINOR_VERSION@, @BINDING_API_MICRO_VERSION@, "@BINDING_API_PRE_RELEASE_VERSION_TYPE@", @BINDING_API_PRE_RELEASE_VERSION@) + +@PYSIDE_BUILD_DATE@ +@PYSIDE_BUILD_COMMIT_DATE@ +@PYSIDE_BUILD_COMMIT_HASH@ +@PYSIDE_BUILD_COMMIT_HASH_DESCRIBED@ + +# Timestamp used for snapshot build, which is part of snapshot package version. +@PYSIDE_SETUP_PY_PACKAGE_TIMESTAMP_ASSIGNMENT@ diff --git a/sources/pyside2/PySide2/typesystem_templates.xml b/sources/pyside2/PySide2/typesystem_templates.xml index 1715c0253..11a384263 100644 --- a/sources/pyside2/PySide2/typesystem_templates.xml +++ b/sources/pyside2/PySide2/typesystem_templates.xml @@ -286,6 +286,12 @@ <template name="return_QString"> %PYARG_0 = %CONVERTTOPYTHON[QString](%1); </template> + <template name="return_QString_native"> + if (%ISCONVERTIBLE[QString](%PYARG_0)) + %1 = %CONVERTTOCPP[QString](%PYARG_0); + else + qWarning("%TYPE::%FUNCTION_NAME: Argument is not convertible to unicode."); + </template> <template name="return_tuple_QValidator_QString_int"> %BEGIN_ALLOW_THREADS |