X-Git-Url: https://git.cweiske.de/enigma2.git/blobdiff_plain/e2e40a2d105f7a4caac0a96dfdbd1282f7922e2b..a1067c78ff03cdc9854f34c5c513ed776d7a2834:/lib/python/enigma_python.i diff --git a/lib/python/enigma_python.i b/lib/python/enigma_python.i index eb814553..16ca40cf 100644 --- a/lib/python/enigma_python.i +++ b/lib/python/enigma_python.i @@ -68,12 +68,15 @@ is usually caused by not marking PSignals as immutable. #include #include #include +#include #include #include #include #include +#include #include #include +#include #include #include @@ -81,6 +84,7 @@ extern void runMainloop(); extern void quitMainloop(int exit_code); extern void setLCD(const char *c); extern void setLCDClock(const char *c); +extern eApplication *getApplication(); extern PSignal1 &keyPressedSignal(); %} @@ -121,6 +125,10 @@ typedef long time_t; %include %include %include + +%immutable eTimer::timeout; +%immutable eSocketNotifier::activated; +%include %include %include %include @@ -136,6 +144,7 @@ typedef long time_t; %immutable pNavigation::m_event; %include +%include %include %include %include @@ -166,12 +175,13 @@ typedef long time_t; %include %include %include +%include %include %include +%include %include %include - -%include +%include /************** eptr **************/ %template(eActionMapPtr) ePtr; @@ -208,20 +218,6 @@ public: $1 = $input->get(); } -/************** base **************/ - -%immutable eTimer::timeout; - -class eTimer -{ -public: - eTimer(eMainloop *context = eApp); - PSignal0 timeout; - - void start(long msec, bool singleShot=false); - void stop(); - void changeInterval(long msek); -}; /************** debug **************/ @@ -229,6 +225,22 @@ void runMainloop(); void quitMainloop(int exit_code); void setLCD(const char*); void setLCDClock(const char*); +eApplication *getApplication(); %immutable keyPressed; PSignal1 &keyPressedSignal(); +%{ +RESULT SwigFromPython(ePtr &result, PyObject *obj) +{ + ePtr *res; + + res = 0; + result = 0; + if (SWIG_Python_ConvertPtr(obj, (void **)&res, SWIGTYPE_p_ePtrTgPixmap_t, SWIG_POINTER_EXCEPTION | 0)) + return -1; + if (!res) + return -1; + result = *res; + return 0; +} +%}