Advertisement
Guest User

Untitled

a guest
Jul 23rd, 2017
56
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.64 KB | None | 0 0
  1. File "./plugins/pythonhello/pythonhello.py", line 10, in <module>
  2. class PythonHelloPlugin(gobject.GObject, Peas.Activatable):
  3. File "/opt/gnome/lib/python2.6/site-packages/gi/types.py", line 217, in __init__
  4. cls._setup_vfuncs()
  5. File "/opt/gnome/lib/python2.6/site-packages/gi/types.py", line 133, in _setup_vfuncs
  6. vfunc_info = find_vfunc_info_in_interface(cls.__bases__, vfunc_name[len("do_"):])
  7. File "/opt/gnome/lib/python2.6/site-packages/gi/types.py", line 182, in find_vfunc_info_in_interface
  8. vfunc = find_vfunc_info_in_interface(base.__bases__, vfunc_name)
  9. File "/opt/gnome/lib/python2.6/site-packages/gi/types.py", line 175, in find_vfunc_info_in_interface
  10. not isinstance(base.__info__, InterfaceInfo):
  11. AttributeError: type object 'gobject.GInterface' has no attribute '__info__'
  12.  
  13.  
  14. import gobject
  15. from gi.repository import Peas
  16. from gi.repository import Gtk
  17. from gi.repository import GLib;
  18. from gi.repository import Mentiras;
  19.  
  20. class PythonHelloPlugin(gobject.GObject, Peas.Activatable):
  21. __gtype_name__ = 'PythonHelloPlugin'
  22.  
  23. object = gobject.property(type=gobject.GObject)
  24.  
  25. def do_activate(self):
  26. window = self.object
  27.  
  28. print "PythonHelloPlugin.do_activate", repr(window);
  29.  
  30. def do_deactivate(self):
  31. window = self.object
  32. print "PythonHelloPlugin.do_deactivate", repr(window)
  33.  
  34. def do_update_state(self):
  35. print "PythonHelloPlugin.do_update_state", repr(self.object)
  36.  
  37. class PythonHelloConfigurable(gobject.GObject, PeasGtk.Configurable):
  38. __gtype_name__ = 'PythonHelloConfigurable'
  39.  
  40. def do_create_configure_widget(self):
  41. return Gtk.Label.new("Python Hello configure widget")
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement