Fix error creation and warning
[claws.git] / src / plugins / python / python-hooks.h
blobd92879bd21c9c13bde3305892c22d0bb319a7be0
1 /*
2 * Copyright (c) 2008-2009 Christian Hammond
3 * Copyright (c) 2008-2009 David Trowbridge
5 * Permission is hereby granted, free of charge, to any person obtaining a
6 * copy of this software and associated documentation files (the "Software"),
7 * to deal in the Software without restriction, including without limitation
8 * the rights to use, copy, modify, merge, publish, distribute, sublicense,
9 * and/or sell copies of the Software, and to permit persons to whom the
10 * Software is furnished to do so, subject to the following conditions:
12 * The above copyright notice and this permission notice shall be included
13 * in all copies or substantial portions of the Software.
15 * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16 * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17 * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18 * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19 * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20 * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
21 * THE SOFTWARE.
23 #ifndef _GTKPARASITE_PYTHON_MODULE_H_
24 #define _GTKPARASITE_PYTHON_MODULE_H_
26 #include <glib.h>
27 #include <Python.h>
30 typedef void (*ParasitePythonLogger)(const char *text, gpointer user_data);
32 PyMODINIT_FUNC parasite_python_module_init(void);
33 int parasite_python_init(char **error);
34 void parasite_python_done(void);
35 void parasite_python_run(const char *command,
36 ParasitePythonLogger stdout_logger,
37 ParasitePythonLogger stderr_logger,
38 gpointer user_data);
39 gboolean parasite_python_is_enabled(void);
41 #endif // _GTKPARASITE_PYTHON_MODULE_H_