From 49db161be97ce0ff71b8fa9fbdf2a00a45ded788 Mon Sep 17 00:00:00 2001 From: Johnny Jacob Date: Wed, 11 Jun 2008 21:22:15 +0000 Subject: A simple example python plugin - just hook onto events. svn path=/trunk/; revision=35627 --- plugins/python/ChangeLog | 10 ++++++++ plugins/python/example/Makefile.am | 30 ++++++++++++++++++++++ plugins/python/example/hello_python.py | 5 ++++ .../python/example/org-gnome-hello-python-ui.xml | 16 ++++++++++++ .../example/org-gnome-hello-python.eplug.xml | 20 +++++++++++++++ 5 files changed, 81 insertions(+) create mode 100644 plugins/python/example/Makefile.am create mode 100644 plugins/python/example/hello_python.py create mode 100644 plugins/python/example/org-gnome-hello-python-ui.xml create mode 100644 plugins/python/example/org-gnome-hello-python.eplug.xml (limited to 'plugins/python') diff --git a/plugins/python/ChangeLog b/plugins/python/ChangeLog index 393e1034b5..43a0bd3482 100644 --- a/plugins/python/ChangeLog +++ b/plugins/python/ChangeLog @@ -1,3 +1,13 @@ +2008-06-12 Johnny Jacob + + * example/org-gnome-hello-python-ui.xml: Added. + + * example/org-gnome-hello-python.eplug.xml: Added. + + * example/Makefile.am : Added. + + * example/hello_python.py: Added. + 2008-06-09 Johnny Jacob * python-plugin-loader.c: Python plugin loader. diff --git a/plugins/python/example/Makefile.am b/plugins/python/example/Makefile.am new file mode 100644 index 0000000000..5defe418c6 --- /dev/null +++ b/plugins/python/example/Makefile.am @@ -0,0 +1,30 @@ +INCLUDES = \ + -DEVOLUTION_GLADEDIR=\""$(gladedir)"\" \ + -DEVOLUTION_IMAGESDIR=\""$(imagesdir)"\" + +@EVO_PLUGIN_RULE@ + +plugin_DATA = \ + hello_python.py \ + org-gnome-hello-python-ui.xml \ + org-gnome-hello-python.eplug + +liborg_gnome_py_plug_test_la_LIBADD= \ + $(NO_UNDEFINED_REQUIRED_LIBS) + +liborg_gnome_py_plug_test_la_LDFLAGS = -module -avoid-version $(NO_UNDEFINED) + +errordir = $(privdatadir)/errors + +BUILDME = org-gnome-hello-python.eplug \ +$(error_i18n) + +BUILT_SOURCES = \ + $(BUILDME) + +EXTRA_DIST = \ + hello_python.py \ + org-gnome-hello-python-ui.xml \ + org-gnome-hello-python.eplug.xml + +CLEANFILES = $(BUILT_SOURCES) diff --git a/plugins/python/example/hello_python.py b/plugins/python/example/hello_python.py new file mode 100644 index 0000000000..16dc2a12f8 --- /dev/null +++ b/plugins/python/example/hello_python.py @@ -0,0 +1,5 @@ +'''hello_python.py - Python source designed to ''' +'''demonstrate the use of python Eplugins''' + +def say_hello(): + print 'Hello ! From python' diff --git a/plugins/python/example/org-gnome-hello-python-ui.xml b/plugins/python/example/org-gnome-hello-python-ui.xml new file mode 100644 index 0000000000..074960e84d --- /dev/null +++ b/plugins/python/example/org-gnome-hello-python-ui.xml @@ -0,0 +1,16 @@ + + + + + + + + + + + + + + diff --git a/plugins/python/example/org-gnome-hello-python.eplug.xml b/plugins/python/example/org-gnome-hello-python.eplug.xml new file mode 100644 index 0000000000..8f77d5ba01 --- /dev/null +++ b/plugins/python/example/org-gnome-hello-python.eplug.xml @@ -0,0 +1,20 @@ + + + + + + + <_description> + Test Plugin for Python EPlugin loader. + + + + + + + + + + + + -- cgit v1.2.3