aboutsummaryrefslogtreecommitdiffstats
path: root/sources/pyside6
Commit message (Collapse)AuthorAgeFilesLines
...
* QML registration code: Introduce a struct for import dataFriedemann Kleint2023-10-231-36/+82
| | | | | | | | Reduces the function parameter count. Task-number: PYSIDE-2484 Change-Id: I53b243ae90600c548a35f5362b47f623c37d9f3f Reviewed-by: Cristian Maureira-Fredes <cristian.maureira-fredes@qt.io>
* QML registration code: Port from std::string to QByteArrayFriedemann Kleint2023-10-237-55/+45
| | | | | | | | | | | | Modern QML registration code is based on QMetaClassInfo, which uses QByteArray; so, this will avoid conversions in the future. As a drive-by, shorten some code and move getGlobal*() helpers to the top for future changes. Task-number: PYSIDE-2484 Change-Id: Iceadca5a42b5fb7cee330e61d543ca712b521ab3 Reviewed-by: Cristian Maureira-Fredes <cristian.maureira-fredes@qt.io>
* QML registration code: Extract a setter from the ClassInfo decoratorFriedemann Kleint2023-10-233-25/+55
| | | | | | | | | | | | | Change it to operate on a list of key/value pairs instead of a QMap (no use in enforcing sorting) and extract a setter for setting QMetaClassInfo data on a PyTypeObject of a QObject. To be used for QML decorators. As a drive-by, fix some static analysis warnings about implicit bool casts. Task-number: PYSIDE-2484 Change-Id: Ia759bb42740ed279f36c0850306ebd9bee526ecf Reviewed-by: Cristian Maureira-Fredes <cristian.maureira-fredes@qt.io>
* Add a separate __str__ function for SignalFriedemann Kleint2023-10-231-2/+16
| | | | | | | | | List all signatures, separated by ';'. Pick-to: 6.6 6.5 Fixes: PYSIDE-2493 Change-Id: I3c7e3367c340ab142a388a3991dc08774b6c7075 Reviewed-by: Christian Tismer <tismer@stackless.com>
* PySide: Fix QLocale crash on macOSShyamnath Premnadh2023-10-182-4/+14
| | | | | | | | | | | | | | | | | | | | | - Reproducible in macOS terminal/QtCreator because the environment does not explicitly set the locale unless the locale is changed. - If the locale of the system has not been changed, then the Python locale module's getLocale() returns 'None' as the language code. In this case, use the POSIX locale or 'C' locale as the default as stated in the Python locale module's documentation: `` According to POSIX, a program which has not called setlocale(LC_ALL, '') runs using the portable 'C' locale. `` - This issue does not exist in VSCode because VSCode set the locale in its terminal. Pick-to: 6.6 6.5 Fixes: PYSIDE-2485 Change-Id: I23ccfa0ef59912ad950143d4a1080c5a201a4865 Reviewed-by: Edward Welbourne <edward.welbourne@qt.io> Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
* doc: add qtpip and Maintenance tool contentCristián Maureira-Fredes2023-10-181-0/+88
| | | | | | | | | Adding information related the inclusion on the Maintenance Tool, and also the qtpip tool Pick-to: 6.6 Change-Id: Ibbce363b28b980ddb406c63d7dbdce8fcffec5f9 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
* deploy: Apply fixes when using pyenv and provide readable errorsChristian Tismer2023-10-181-45/+86
| | | | | | | | | | | | | | | | | | | | When the patch for pyenv was applied, some tests in test_pyside6_deploy.py were broken, which shows up locally but not (yet) in CI. For better understanding, the test classes were further broken up into three groups (irrelevant, might be undone). Things became clearer by writing a special version of unittest.TestCase that handles long strings as lists. REMARK: We are at Python 3.8 and can use ":=" now :=) Task-number: PYSIDE-1612 Change-Id: I3a479f48b96dd5f95864b8a94af6d01b42ffc196 Reviewed-by: Cristian Maureira-Fredes <cristian.maureira-fredes@qt.io> Reviewed-by: Shyamnath Premnadh <Shyamnath.Premnadh@qt.io> Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
* Fix Unity build of QtQuickFriedemann Kleint2023-10-181-2/+10
| | | | | | | | | | | | | | qsgrendernode_renderstate_wrapper.cpp and qsgmaterialshader_renderstate_wrapper.cpp have static helper functions named "renderstate_..." that might clash when the order changes due further sources being added. Amends 277783b47e704505f19d00dd80f26239082974d6. Pick-to: 6.6 6.5 Task-number: PYSIDE-2155 Change-Id: I9873f2697b03aa1650847d0daaa622930d74c39d Reviewed-by: Shyamnath Premnadh <Shyamnath.Premnadh@qt.io>
* UiTools/Designer plugins: Fix some static code analysis warningsFriedemann Kleint2023-10-175-28/+34
| | | | | | | | | | | Fix warnings about implicit cast to bool (pointer/int). Fix some auto * definitions of pointers. As a drive-by, modernize string constants. Pick-to: 6.6 6.5 Change-Id: I05f83de9299dd91e80fc4252514f6cbbebcf1cfc Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org> Reviewed-by: Cristian Maureira-Fredes <cristian.maureira-fredes@qt.io>
* Improve error messages around signal/slot connectionsFriedemann Kleint2023-10-172-5/+7
| | | | | | | Task-number: PYSIDE-2487 Pick-to: 6.6 6.5 Change-Id: I93d2c350aecf1339c6b18496f376d04cdd37dc29 Reviewed-by: Cristian Maureira-Fredes <cristian.maureira-fredes@qt.io>
* libpyside: Implement QMetaMethod::tags() for @SlotFriedemann Kleint2023-10-174-8/+23
| | | | | | | | | | | | | Tags can be used like annotations and are for example used in the DBus module. [ChangeLog][PySide6] An optional parameter "tag" has been added to @Slot, allowing to set QMetaMethod.tag(). Pick-to: 6.6 Fixes: PYSIDE-748 Change-Id: I62bef6179917307471cb72491ac3d05970572f3f Reviewed-by: Cristian Maureira-Fredes <cristian.maureira-fredes@qt.io>
* Remove registry existence files of 5.15Friedemann Kleint2023-10-174-151055/+0
| | | | | | | Pick-to: 6.6 6.5 Change-Id: I5fef2da79500ca40400ba7943183ab22d85ad22d Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org> Reviewed-by: Cristian Maureira-Fredes <cristian.maureira-fredes@qt.io>
* Support running PySide on Python 3.12, QML bugChristian Tismer2023-10-171-2/+7
| | | | | | | | | | | An old thinking error was found that caused too late deletion of an object. Note: The AutoDecref construct should never be used in a static context. Task-number: PYSIDE-2230 Change-Id: If6519014f564ed86ee95bd45e14ba4821274aea6 Pick-to: 6.2 6.5 6.6 Reviewed-by: Adrian Herrmann <adrian.herrmann@qt.io>
* Support running PySide on Python 3.12, cleanupChristian Tismer2023-10-162-1/+5
| | | | | | | | | | | | | | | | | In the course of fixing 3.12 issues, a 3.11 fix for PyEnum was missing that created a 3.11 error. A bug with deployment was fixed but not reflected in the tests. This was only visible for pyenv users. Also fixes a minor cosmetic bug introduced by "Python 3.12: Fix the structure of class property" Task-number: PYSIDE-2230 Change-Id: I3a6bd6426e23168dfccdda17b408f193aacd28a0 Pick-to: 6.2 6.5 6.6 Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org> Reviewed-by: Cristian Maureira-Fredes <cristian.maureira-fredes@qt.io>
* Fix Unity build of QtGuiFriedemann Kleint2023-10-141-2/+10
| | | | | | | | | | | | | qtextframe_iterator_wrapper.cpp and qtextblock_iterator_wrapper.cpp have static helper functions named "iterator_..." that might clash when the order changes due further sources being added. Amends 277783b47e704505f19d00dd80f26239082974d6. Pick-to: 6.6 6.5 Task-number: PYSIDE-2155 Change-Id: Ib545b8a08be400b9243a0a1d85827e2e97782666 Reviewed-by: Cristian Maureira-Fredes <cristian.maureira-fredes@qt.io>
* Fix crash when running a limited API build of 3.9 in 3.12Friedemann Kleint2023-10-132-2/+11
| | | | | | | | | | | | The size of propertyobject as needed as basic size of PyClassProperty_spec needs to be adapted according to runtime version. Otherwise, PyType_FromSpecWithBases fails with: TypeError: tp_basicsize for type 'PySide6.QtCore.PyClassProperty' (56) is too small for base 'property' (64) Pick-to: 6.6 6.5 Task-number: PYSIDE-2230 Change-Id: I03788edbb7031577f37db0fb2eb029b41f37c5f1 Reviewed-by: Shyamnath Premnadh <Shyamnath.Premnadh@qt.io>
* Fix disconnecting non-decorated slot of base class from signalFriedemann Kleint2023-10-131-1/+2
| | | | | | | | | | | | | | | Further tighten the check for non-virtual slots overwritten in Python by checking that the QMetaObject actually returns a different declaring class. This works around the underlying issue that the logic automatically creating meta methods for non-decorated slots wrongly adds the entry to the derived class. Amends f048d13b4f042b04d94007fba951ed3080ccf8c9. Task-number: PYSIDE-2418 Fixes: PYSIDE-2487 Pick-to: 6.6 6.5 Change-Id: I0c62cfd9fd6dcb2ddf6bcfd1db14aa274293b34f Reviewed-by: Cristian Maureira-Fredes <cristian.maureira-fredes@qt.io>
* Output the runtime version in QLibraryInfo::build()Friedemann Kleint2023-10-131-5/+9
| | | | | | | Pick-to: 6.6 Task-number: PYSIDE-2230 Change-Id: Id365e1dac6a4486dd1ff995dde9b834cf6bf95b4 Reviewed-by: Cristian Maureira-Fredes <cristian.maureira-fredes@qt.io>
* Fix a warning resulting from bumping Python to 3.8Friedemann Kleint2023-10-121-2/+2
| | | | | | | | | | | | Remove PepIndex_Check, fixing: Python is at version 3.8 now. The file pep384_issue33738.cpp should be removed ASAP! Amends bcfd0a1ad2f1c333b53db071fe40b2ee3569bd6b. Task-number: PYSIDE-1797 Pick-to: 6.6 Change-Id: Id195395fc81899c3881b2f9c6767e25d5bf8fb3d Reviewed-by: Shyamnath Premnadh <Shyamnath.Premnadh@qt.io>
* QtAsyncio: Don't schedule events when quitting appAdrian Herrmann2023-10-111-1/+12
| | | | | | | | | | | Do not schedule events from asyncio when the app is quit from outside the event loop, as this would cause events to be enqueued after the event loop was destroyed. Pick-to: 6.6 Task-number: PYSIDE-769 Change-Id: Ib9ff3949653783e4a9484a8a28f1c0010dcff33f Reviewed-by: Cristian Maureira-Fredes <cristian.maureira-fredes@qt.io>
* shiboken: Get rid of tp_dict in general, amendedChristian Tismer2023-10-112-4/+5
| | | | | | | | | | | | | | | | | | A few more cases of cppgenerator were added. This are now really all cases, because tp_dict is no longer exported. As a very positive side effect, there is no longer direct tp_dict access in the "init_<type>" functions. Usage of PepType_GetDict would have created a permanent extra-reference. NOTE: It was necessary to set SKIP_UNITY_BUILD_INCLUSION on pep384impl.cpp in order to let this work with unity. Change-Id: I021dbc978b51265db96d5d3d438e06aa96230cc1 Pick-to: 6.2 6.5 6.6 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
* Desktop Deployment: Update docsShyamnath Premnadh2023-10-101-1/+5
| | | | | | | Task-number: PYSIDE-1612 Pick-to: 6.6 6.5 Change-Id: I825b3cf13aba173313bcbef74d2007d3ca4c12b0 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
* shiboken6: Fix some static code analysis warnings in the generated codeFriedemann Kleint2023-10-101-2/+2
| | | | | | | | | | | | | Remove left-over reinterpret_cast<> from SbkType to PyType (SbkType was removed). Fix warnings about implicit cast to bool (pointer/int). Fix some auto * definitions of pointers. Generate wrapper destructors as override when applicable. Pick-to: 6.6 6.5 Change-Id: I961a1c64821bbf0f2648f5e897029f1aa7d61a43 Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org> Reviewed-by: Shyamnath Premnadh <Shyamnath.Premnadh@qt.io>
* pysidetest: Fix some static code analysis warningsFriedemann Kleint2023-10-106-10/+13
| | | | | | Pick-to: 6.6 6.5 Change-Id: If0050eadfc36444300b61498e46034ad3b4c8cdd Reviewed-by: Shyamnath Premnadh <Shyamnath.Premnadh@qt.io>
* shiboken: Get rid of tp_dict in generalChristian Tismer2023-10-093-20/+29
| | | | | | | | | | | | | | It is a long due task to finally remove the direct access to type object fields. With Python 3.12, direct access to tp_dict became problematic. We use that as a reason to start removing the direct access in favor of function calls. Task-number: PYSIDE-2230 Change-Id: I6f8a7479ab0afdbef14d4661f66c3588f3a578aa Pick-to: 6.2 6.5 6.6 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
* Support running PySide on Python 3.12Christian Tismer2023-10-096-11/+37
| | | | | | | | | | | | | | | | | | Builtin types no longer have tp_dict set. We need to use PyType_GetDict, instead. This works without Limited API at the moment. With some great cheating, this works with Limited API, too. We emulate PyType_GetDict by tp_dict if that is not 0. Otherwise we create an empty dict. Some small changes to Exception handling and longer warm-up in leaking tests were found, too. Pick-to: 6.6 6.5 6.2 Task-number: PYSIDE-2230 Change-Id: I8a56de6208ec00979255b39b5784dfc9b4b92def Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
* libshiboken/libpyside: Fix special functionsFriedemann Kleint2023-10-067-1/+19
| | | | | | | | Pick-to: 6.6 Task-number: PYSIDE-2479 Change-Id: I6df19d487be7087f17e37bea3ea30a66e9b24ed7 Reviewed-by: Shyamnath Premnadh <Shyamnath.Premnadh@qt.io> Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
* libshiboken: Deprecate cast operators of AutoDecRefFriedemann Kleint2023-10-053-4/+6
| | | | | | | | | | | | | | | For the non-limited API case, there was a cast to PyTupleObject * required for argument tuples due to the PyTuple_GET_ITEM() macro definition. Replace it by calling object(). Also deprecate the universal cast function. [ChangeLog][shiboken6] Cast operators of the helper class AutoDecRef have been deprecated. Pick-to: 6.6 Task-number: PYSIDE-2479 Change-Id: Iff660fbc791b1a74ecbd247e71edc896767f308d Reviewed-by: Shyamnath Premnadh <Shyamnath.Premnadh@qt.io>
* Fix failing XML testFriedemann Kleint2023-10-051-1/+0
| | | | | | | | | Remove the check for error column, adapting to qtbase/3d631da88bc08816b72493dbce785cabc56b70be. Pick-to: 6.6 6.5 Change-Id: Ic3deb32ba7b8c57af794ae4df7088a1d3044fbdb Reviewed-by: Shyamnath Premnadh <Shyamnath.Premnadh@qt.io>
* Fix crash of test registersingletontype.py in Qt 6.7Friedemann Kleint2023-10-021-49/+58
| | | | | | | | | | | | | | | | | In f3f8939f347370dbd2738ecb536543bf8cff4a09, a second occurrence of QQmlPrivate::RegisterSingletonType in qmlRegisterSingletonInstance() was overlooked. Take the opportunity to brace-initialize the QML register structs such that further additions to them will then show up as warnings or errors. Pick-to: 6.6 6.5 6.2 Task-number: PYSIDE-2433 Change-Id: Ia2af115193531543522d427764e70130339af007 Reviewed-by: Cristian Maureira-Fredes <cristian.maureira-fredes@qt.io> Reviewed-by: Shyamnath Premnadh <Shyamnath.Premnadh@qt.io> Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
* QtAsyncio: Add _cancel_message to future + taskAdrian Herrmann2023-10-022-0/+3
| | | | | | | | | | This field is assumed by asyncio.gather() to exist in task or future classes despite being undocumented. Pick-to: 6.6 Task-number: PYSIDE-769 Change-Id: Ieab6f216db95e40bd02625fb9cff69be0ebccd50 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
* QtAsyncio: Do not stop loop at task completionAdrian Herrmann2023-10-021-1/+0
| | | | | | | | | | | An erroneous self._loop.stop() has sneaked into the end of QAsyncioTask._step, causing the event loop to stop prematurely in some scenarios. Pick-to: 6.6 Task-number: PYSIDE-769 Change-Id: If155e43f81675c660766c00e766e8a8f3bbe8b38 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
* QtAsyncio: Miscellaneous improvements to TaskAdrian Herrmann2023-09-291-5/+9
| | | | | | | | | | | - Use asyncio._register_task() and asyncio._unregister_task() as demanded by the API (extending asyncio, Task lifetime support) - Add some comments and a missing return type in signature Pick-to: 6.6 Task-number: PYSIDE-769 Change-Id: I3ffdf0dc5f7b127c0dd9f2fb63eecb057d123744 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
* Replace QPair by std::pairFriedemann Kleint2023-09-292-4/+5
| | | | | | Pick-to: 6.6 6.5 Change-Id: Ic64a2a2c162c54fbbfb6ddc5004ffe1944bfd37a Reviewed-by: Shyamnath Premnadh <Shyamnath.Premnadh@qt.io>
* Fix qsqldatabaseandqueries_test.py to work in Qt 6.7Friedemann Kleint2023-09-281-4/+4
| | | | | | | | | | | | Inherit UsesQApplication to ensure a QApplication is present, which is now always required. Since one test instantiated a Application, this is the better solution regardles of whether the underlying issue is fixed in Qt. Task-number: QTBUG-117621 Pick-to: 6.6 6.5 Change-Id: I420dadb6c2f90314fe401aaf9291d23f5986bce3 Reviewed-by: Shyamnath Premnadh <Shyamnath.Premnadh@qt.io>
* Avoid some string conversionsFriedemann Kleint2023-09-272-4/+6
| | | | | | | | | Remove some usages of String::toCString(func_name) and construction of a QByteArray. Pick-to: 6.6 6.5 Change-Id: I9fb29341fba1be205e70d8d5ffc1a6d258ef87dd Reviewed-by: Shyamnath Premnadh <Shyamnath.Premnadh@qt.io>
* Refactor signal helper extractFunctionArgumentsFromSlot()Friedemann Kleint2023-09-271-78/+68
| | | | | | | | | | | | | Replace out parameters by a struct and streamline code accordingly. Return the function name as a PyObject to be able to delay the conversion. Fix some implicit bool conversions along the way. Pick-to: 6.6 6.5 Task-number: PYSIDE-229 Task-number: PYSIDE-2423 Change-Id: I0dcf14f5b719529117c0ccc119fb19802b399a35 Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org> Reviewed-by: Shyamnath Premnadh <Shyamnath.Premnadh@qt.io>
* Improve libpyside debug operatorsFriedemann Kleint2023-09-261-0/+31
| | | | | | | | | | | | Output True/False directly. Also output methods and functions. Amends 74a2ec0202af250828c10dfb10b71036a3af9dd8. Task-number: PYSIDE-229 Pick-to: 6.6 Change-Id: I3625853ec5deef03cb6f94f24e0a2e80d4ac30a7 Reviewed-by: Christian Tismer <tismer@stackless.com> Reviewed-by: Adrian Herrmann <adrian.herrmann@qt.io>
* Replace typedef by usingFriedemann Kleint2023-09-209-24/+22
| | | | | | | Pick-to: 6.6 6.5 Change-Id: I23d8ea03ec578a897352c2627417a706ca71ef82 Reviewed-by: Shyamnath Premnadh <Shyamnath.Premnadh@qt.io> Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
* libshiboken/libpyside: Fix some static analysis warningsFriedemann Kleint2023-09-2010-20/+17
| | | | | | | | | | | | - nullptr - narrowing integer conversions - else after return - Use auto - Missing move special functions Pick-to: 6.6 6.5 Change-Id: Ib872481a46c8bb17592cdc1778ab3c4d9598c753 Reviewed-by: Shyamnath Premnadh <Shyamnath.Premnadh@qt.io>
* Fix namespacesFriedemann Kleint2023-09-2020-90/+51
| | | | | | | | | | | - Use nested namespaces instead repetitive namespace declaration - Remove anonymous namespaces that contain only static functions. "static" is sufficient here, the anonymous namespace only increases compilation time. Pick-to: 6.6 6.5 Change-Id: I6cd1b63da79eaf40a1b7ae031def97fa22903e99 Reviewed-by: Shyamnath Premnadh <Shyamnath.Premnadh@qt.io>
* QtAsyncio: Fix signature of cancel for future/taskAdrian Herrmann2023-09-192-3/+7
| | | | | | | | | | QAsyncioFuture.cancel() and QAsyncioTask.cancel() should both return a bool. Pick-to: 6.6 Task-number: PYSIDE-769 Change-Id: I2b507ad5c44ba9478bdf8a53c0cd5464028d3384 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
* QtAsyncio: Use asyncio._enter_task and _leave_taskAdrian Herrmann2023-09-191-0/+5
| | | | | | | | | | Wrap a QAsyncioTask's step execution with calls to asyncio._enter_task() and asyncio._leave_task() so that asyncio.current_task() will work. Pick-to: 6.6 Task-number: PYSIDE-769 Change-Id: I7235c9ab2b8d68b0059b82a366909dc25ea6d60f Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
* Fix a debug mode assert in QDataStream.writeRawData() in ↵Friedemann Kleint2023-09-181-1/+1
| | | | | | | | | | | | | | | QtCore/qdatastream_test.py Shiboken::Buffer::getPointer() asserts with in Py_BEGIN_ALLOW_THREADS/Py_END_ALLOW_THREADS since some nested function cannot retrieve the thread state. Amends 940cad174f891a4b04af9bcc61aed1c8e8c6d4ae. Pick-to: 6.6 Task-number: PYSIDE-2442 Change-Id: I27ca9fc485cf81fb47747db7cc40623a9f7fffec Reviewed-by: Shyamnath Premnadh <Shyamnath.Premnadh@qt.io>
* PySide6: Fix some type hintsFriedemann Kleint2023-09-132-1/+4
| | | | | | | | Pick-to: 6.5 Task-number: PYSIDE-2463 Change-Id: I5a1fba3d7d86b44f7fb35f9ed263481a4b850408 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io> Reviewed-by: Adrian Herrmann <adrian.herrmann@qt.io>
* QtAsyncio: Add queues testAdrian Herrmann2023-09-124-6/+79
| | | | | | | | | | Add a test for the asyncio queue for consumer/producer scenarios. Additionally, fix a few bugs exposed by this test through the increased code coverage. Task-number: PYSIDE-769 Change-Id: I18e3be6d059b758868a7598b58704db216bcdcc8 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
* QtAsyncio: Fix time unitAdrian Herrmann2023-09-123-8/+57
| | | | | | | | | loop.time() needs to return the time in seconds as a float, not in milliseconds as an int. Task-number: PYSIDE-769 Change-Id: Iac123132b49d3954abda8545d0830f1837a27c48 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
* macOS wheel creation: Fix wheel nameShyamnath Premnadh2023-09-081-0/+1
| | | | | | | | | | | | | - The macOS version in the wheel name was picked up from Python's build configuration instead of Qt. - The solution involves writing the cmake variable QT_DARWIN_MIN_DEPLOYMENT_TARGET into _config.py, and create_wheels.py loads this _config.py to fetch the python variable storing it. Pick-to: 6.5 Fixes: PYSIDE-2429 Change-Id: I85003174b83ba937c8b3e1498b728f13d960284e Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
* PySide: Add requestPermission()Shyamnath Premnadh2023-09-082-0/+87
| | | | | | | | | | | | | | | | - Only relevant for platforms like Android, where QT_FEATURE_permissions is turned ON. - Used a callback from the wrapper code to establish a call back to the passed Python functor. - The passed functor can either have no parameters, or have a QPermission object as parameter. In the latter case, the QPermission object will store the result of requestPermission(). This is similar to the Qt API. Pick-to: 6.5 Task-number: PYSIDE-1612 Change-Id: I0de8d1c67e69590d2a63ee51c61dfb3a8b76a43f Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
* PySide: Add checkPermission()Shyamnath Premnadh2023-09-081-0/+8
| | | | | | | | | | | | | | | | - QPermission is an opaque wrapper around typed Permissions. The conversion from specific typed Permission to QPermission for usage within API functions like checkPermission(QPermission) involved implicit conversion from the typed Permission to QPermission through a templated constructor. Therefore, Shiboken needs to handle each of the conversions explicitly. - Only relevant for platforms like Android, where QT_FEATURE_permissions is turned ON. Pick-to: 6.5 Task-number: PYSIDE-1612 Change-Id: I097bf6f24a7ac79e9a62455dab9f3c8bdf6b8246 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>