summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorSebastien Estienne <sebastien.estienne@gmail.com>2007-03-26 20:34:56 +0000
committerSebastien Estienne <sebastien.estienne@gmail.com>2007-03-26 20:34:56 +0000
commitebc1f260f19e217b5974aef412c904bcc23d3c37 (patch)
treef23924be94e5d3b447763a59259d023dfce03df1 /src
parent91addfab698fb6111e6a4d02185273eefe40efa6 (diff)
display an error message when an error occur whith nautilus plugin
git-svn-id: file:///home/lennart/svn/public/service-discovery-applet/trunk@137 3be567f1-68ff-0310-b24a-ad7cc433fd2f
Diffstat (limited to 'src')
-rw-r--r--src/modules/pluginutils.py13
1 files changed, 13 insertions, 0 deletions
diff --git a/src/modules/pluginutils.py b/src/modules/pluginutils.py
index 61f1a3d..f1e0ea4 100644
--- a/src/modules/pluginutils.py
+++ b/src/modules/pluginutils.py
@@ -12,6 +12,19 @@
# $id$
#
+import pygtk
+import gtk
+
+pygtk.require('2.0')
+
+def error_msg(msg):
+ d = gtk.MessageDialog(parent=None, flags=gtk.DIALOG_MODAL,
+ type=gtk.MESSAGE_ERROR, buttons=gtk.BUTTONS_OK)
+ d.set_markup(msg)
+ d.show_all()
+ d.run()
+ d.destroy()
+
def pair_to_dict(l):
res = dict()
for el in l: