Error with gtk.gdk.threads_init()
Brought to you by:
fabioz
I imported the package gtk
import gtk
And then call
gtk.gdk.threads_init()
(I'm writing a PyGTK multithreaded application)
The code runs fine, but PyDev indicates the following error in the line above:
Undefined variable from import: threads_init
I'm using:
PyDEV 1.3.10
Eclipse SDK 3.3.1.1
Ubuntu 7.10 "Gutsy Gibbon"
Python 2.5.1, PyGTK 2.12.0 (Gtk+ 2.12.0)
Logged In: YES
user_id=617340
Originator: NO
Try adding pygtk to the 'forced builtins' (http://www.fabioz.com/pydev/manual_101_interpreter.html)
Logged In: YES
user_id=1945818
Originator: YES
Thanks, adding gtk (not pygtk) to 'forced builtins' solved the problem. I did the same thing with gobject, too.