Skip to content
Snippets Groups Projects
Commit a7ec7335 authored by Jan Möbius's avatar Jan Möbius
Browse files

Ifdefs to disable pythonInterpreter in python widget

parent 909be985
No related branches found
No related tags found
1 merge request!127Python support
...@@ -40,15 +40,17 @@ ...@@ -40,15 +40,17 @@
\*===========================================================================*/ \*===========================================================================*/
#ifdef PYTHON_ENABLED
#include <pybind11/include/pybind11/pybind11.h> #include <pybind11/include/pybind11/pybind11.h>
#include <pybind11/include/pybind11/embed.h> #include <pybind11/include/pybind11/embed.h>
#include <OpenFlipper/PythonInterpreter/PythonInterpreter.hh>
#endif
#include "pythonWidget.hh" #include "pythonWidget.hh"
#include <iostream> #include <iostream>
#include <QObject> #include <QObject>
#include <OpenFlipper/PythonInterpreter/PythonInterpreter.hh>
//#include <dlfcn.h> //#include <dlfcn.h>
...@@ -91,10 +93,11 @@ PythonWidget::PythonWidget(QWidget *parent ) ...@@ -91,10 +93,11 @@ PythonWidget::PythonWidget(QWidget *parent )
void PythonWidget::runScript() { void PythonWidget::runScript() {
#ifdef PYTHON_ENABLED
PythonInterpreter* interpreter = PythonInterpreter::getInstance(); PythonInterpreter* interpreter = PythonInterpreter::getInstance();
interpreter->runScript(scriptWidget->toPlainText()); interpreter->runScript(scriptWidget->toPlainText());
#endif
} }
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment