summaryrefslogtreecommitdiff
path: root/gr-qtgui/lib/histogram_sink_f_impl.cc
diff options
context:
space:
mode:
authorSylvain Munaut <tnt@246tNt.com>2014-03-14 23:17:58 +0100
committerSylvain Munaut <tnt@246tNt.com>2014-03-15 07:18:20 +0100
commit6a78af5919133fdc339b09bb1622e876365a4d19 (patch)
tree84911bcf90be76ea212c2f25e2f752b1a442be60 /gr-qtgui/lib/histogram_sink_f_impl.cc
parent69dcaa75b629af4ebc465a073f54af84b7c75a11 (diff)
gr-qtgui: Use dummy void* return value for pywidget if !ENABLE_PYTHON
This has two benefits: - If ENABLE_PYTHON is disabled during build, the method will still be there and just return NULL - During build of external projects / apps that don't necessarely want to have python included in the build, the exposed vtable is the same as the one from GR (whether or not python was enabled during GR build) Without this, using those block from outside without the exact same option as during GR build would result in crash. Signed-off-by: Sylvain Munaut <tnt@246tNt.com>
Diffstat (limited to 'gr-qtgui/lib/histogram_sink_f_impl.cc')
-rw-r--r--gr-qtgui/lib/histogram_sink_f_impl.cc6
1 files changed, 6 insertions, 0 deletions
diff --git a/gr-qtgui/lib/histogram_sink_f_impl.cc b/gr-qtgui/lib/histogram_sink_f_impl.cc
index 4b3aa29693..dc3e63cb01 100644
--- a/gr-qtgui/lib/histogram_sink_f_impl.cc
+++ b/gr-qtgui/lib/histogram_sink_f_impl.cc
@@ -150,6 +150,12 @@ namespace gr {
PyObject *retarg = Py_BuildValue("N", w);
return retarg;
}
+#else
+ void *
+ histogram_sink_f_impl::pyqwidget()
+ {
+ return NULL;
+ }
#endif
void