25 #ifndef KARAMBA_PYTHON_H
26 #define KARAMBA_PYTHON_H
35 typedef struct _object PyObject;
37 typedef struct _ts PyThreadState;
43 bool pythonThemeExtensionLoaded;
44 PyObject *pName, *pModule;
46 static PyThreadState* mainThreadState;
48 void getLock(PyThreadState** myThreadState);
49 PyObject* getFunc(
const char*
function);
50 void releaseLock(PyThreadState* myThreadState);
51 bool callObject(
const char* func, PyObject* pArgs,
bool lock=
true);
54 KarambaPython(
const ThemeFile& theme,
bool reloading);
57 static void initPython();
58 static void shutdownPython();
60 bool isExtensionLoaded() {
return pythonThemeExtensionLoaded; };
61 bool initWidget(karamba* k);
62 bool widgetUpdated(karamba* k);
63 bool widgetClosed(karamba* k);
64 bool menuOptionChanged(karamba* k, TQString key,
bool value);
65 bool meterClicked(karamba* k, Meter* meter,
int button);
66 bool meterClicked(karamba* k, TQString anchor,
int button);
67 bool widgetClicked(karamba* k,
int x,
int y,
int button);
68 bool keyPressed(karamba* k,
const Meter* meter,
const TQString& text);
69 bool widgetMouseMoved(karamba* k,
int x,
int y,
int button);
70 bool menuItemClicked(karamba* k, TDEPopupMenu* menu,
long id);
71 bool activeTaskChanged(karamba* k,
Task* t);
72 bool taskAdded(karamba* k,
Task* t);
73 bool taskRemoved(karamba* k,
Task* t);
74 bool startupAdded(karamba* k,
Startup* t);
75 bool startupRemoved(karamba* k,
Startup* t);
76 bool commandOutput(karamba* k,
int pid,
char *buffer);
77 bool commandFinished(karamba* k,
int pid);
78 bool itemDropped(karamba* k, TQString text,
int x,
int y);
79 bool themeNotify(karamba* k,
const char *from,
const char *txt);
80 bool systrayUpdated(karamba* k);
81 bool desktopChanged(karamba* k,
int desktop);
82 bool wallpaperChanged(karamba* k,
int desktop);
Represents a task which is in the process of starting.
A dynamic interface to a task (main window).