After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 597842 - Uses libgnome (python bindings) which is deprecated
Uses libgnome (python bindings) which is deprecated
Status: RESOLVED FIXED
Product: gnome-applets
Classification: Other
Component: invest-applet
2.28.x
Other Linux
: Normal normal
: ---
Assigned To: gnome-applets Maintainers
gnome-applets Maintainers
Depends on:
Blocks:
 
 
Reported: 2009-10-08 18:31 UTC by Emilio Pozuelo Monfort
Modified: 2010-04-27 21:03 UTC
See Also:
GNOME target: 3.0
GNOME version: ---


Attachments
removes the libgnome dependency from the sources (964 bytes, patch)
2010-01-18 15:31 UTC, Enrico Minack
committed Details | Review

Description Emilio Pozuelo Monfort 2009-10-08 18:31:12 UTC
libgnome is deprecated (and so are the python bindings). The invest applet uses it in two places:

about.py:
from gnome import url_show
gtk.about_dialog_set_email_hook(lambda dialog, email: url_show("mailto:%s" % email))


and invest-applet.py:
	if standalone:
		import gnome
		gnome.init(invest.defs.PACKAGE, invest.defs.VERSION)
Comment 1 Callum McKenzie 2010-01-14 07:51:06 UTC
gnome.show_url -> gtk.show_uri
(note the change from url to uri, which is probably why a search for it didn't find it)

gnome.init can probably be dropped completely. Officially it is replaced with gnome_program_init (from the libgnomeui library), but looking at the description of what that function does, I think its safe to not use it.
Comment 2 Enrico Minack 2010-01-18 15:31:14 UTC
Created attachment 151672 [details] [review]
removes the libgnome dependency from the sources

Changed the sources accordingly. Does the make framework have to be adopted? I did not find anything related in the invest project.
Comment 3 Javier Jardón (IRC: jjardon) 2010-04-15 15:58:03 UTC
ping, Could this get a review?
Comment 4 Frederic Peters 2010-04-27 14:35:37 UTC
Works for me.
Comment 5 Javier Jardón (IRC: jjardon) 2010-04-27 19:36:45 UTC
Review of attachment 151672 [details] [review]:

Tested here too and all seems to work ok.

Only a little comment:

::: invest-applet/invest/about.py
@@ +8,1 @@
+gtk.about_dialog_set_email_hook(lambda dialog, email: gtk.show_uri(None, "mailto:%s" % email, gtk.gdk.CURRENT_TIME))

You can remove this line. The default handler is ok
Comment 6 Javier Jardón (IRC: jjardon) 2010-04-27 21:03:03 UTC
Comment on attachment 151672 [details] [review]
removes the libgnome dependency from the sources

committed the Enrico with my comments ;)

commit 169b8f99e370f1577593ef5071c33d8ec641f4ee