summaryrefslogtreecommitdiff
path: root/gr-qtgui/python/qtgui/bindings/const_sink_c_python.cc
Commit message (Collapse)AuthorAgeFilesLines
* qtgui: Replace pyqwidget() with qwidget()David Winter2021-09-031-12/+4
| | | | | | | | | | | | | | | | | | | | | | | | | Previously, two versions of the `qtwidget` functions existed, `qwidget()` and `pyqwidget()`, with the only difference being that `qwidget()` returned a pointer to the `QWidget` object managed by the corresponding block, while `pyqwidget()` returned that same pointer, but as an integer (Or `PyLong` in this case). While `qwidget()` is used by C++ code accessing the widgets, `pyqwidget()` is only used for the python interface. This makes these two methods redundant, thus this commit entirely removes `pyqwidget()`, and modifies the `qwidget()` python wrapper to behave like `pyqwidget()`. Note that we can be fairly confident that this change will not effect potential users of `qwidget()`, because any invocation on the objects previously returned by `qwidget()` would cause a segmentation fault. This commit also fixes a memory leak: Internally, the `pyqwidget()` functions were returning a PyLong `PyObject *`, which was then upwrapped in a pybind trampoline without decrementing the reference count of that python object. Signed-off-by: David Winter <david.winter@analog.com>
* qtgui: python: bindings: Use nullptr instead of nonstandard __null.Ryan Volz2020-10-051-1/+1
| | | | This fixes compilation with MSVC.
* gr-qtgui: Replace PyLong_AsLong with PyLong_AsLongLong for 32-bit systems.Ron Economos2020-06-291-2/+4
|
* qtgui: add pybind11 bindingsJosh Morman2020-06-041-0/+238