{"push_id":2081022930,"size":1,"distinct_size":1,"ref":"refs/heads/5.6","head":"e30e0c161b2b4d50484314bf006e9e5e8ff6b380","before":"8ff047b26dd7e928bd35c519fb9e18db4d1b9a94","commits":[{"sha":"e30e0c161b2b4d50484314bf006e9e5e8ff6b380","author":{"name":"Christian Tismer","email":"c7e15e97f7df1a816ae65fbb0145f1c8962708ba@stackless.com"},"message":"Support the qApp macro correctly, final version incl. debug\n\nFor short the new features:\n- there is a qApp in QtCore, QtGui and QtWidgets for compatibility,\n  and also in __builtins__ for a true macro-like experience.\n- if you delete any qApp variable, the Q*Application is reset and you can\n  start over.\n\nLong description:\n\nThere is a qApp macro in Qt5 which is equivalent to Q*Application.instance() .\n\nPython does not have macros. Both PyQt5 and PySide2 have an\naccording structure in QtWidgets. In the case of PySide2, the qApp\nvariable is first initialized to None and later to QApplication().\n\nThis does not reflect the original sense of the qApp macro, because\n - it only handles QApplication,\n - it does not handle destruction.\n\nThis \"macro\" should live in QtCore, but both PyQt5 and PySide2 decided\nto put this in QtWidgets. As a compromize, I propose to put qApp into\nall three modules, and into __builtins__ as well, so wherever you\ncreate an application, you find this \"macro\" in place.\n\nWhile changing the code, I stumbled over the template\nset_qapp_parent_for_orphan. I tried to make sense out of it and finally\nremoved it. There were no side effects but bug PYSIDE-85 is gone, now.\n\nWith some extra effort, I created a singleton qApp that changes itself.\nThis way, a true macro was simulated. Note that this was not possible\nwith a garbage collected variable, and I had to make shiboken aware of this.\n\nAs the final optimization, I turned qApp also into a fuse variable:\nDelete any qApp variable and Q*Application will finish when there is\nno extra reference.\n\nTask-number: PYSIDE-85\nTask-number: PYSIDE-571\nChange-Id: I7a56b19858f63349c98b95778759a6a6de856938\nReviewed-by: Christian Tismer <tismer@stackless.com>","distinct":true,"url":"https://api.github.com/repos/qtproject/pyside-pyside-setup/commits/e30e0c161b2b4d50484314bf006e9e5e8ff6b380"}]}
{"actor":{"display_login":"qtprojectorg"}}