GNOME Bugzilla – Bug 778726
Use gtk_show_uri_on_window()
Last modified: 2017-02-16 15:44:38 UTC
We use gtk_show_uri() in various places, and now that it has been deprecated it raises compiler warnings. The use in GtkLabel is trivial, but GtkFileChooserWidget and GtkPrintOperation is a bit more complicated.
Created attachment 345902 [details] [review] Use gtk_show_uri_on_window() in GtkLabel Avoid the deprecated gtk_show_uri(), and allow activating link in sandboxed applications.
Created attachment 345912 [details] [review] docs: Fix reference to non-existent gtk_show_uri_on_parent() It's called gtk_show_uri_on_window().
Created attachment 345913 [details] [review] docs: Advise to use gtk_show_uri_on_window() Instead of gtk_show_uri() which is now deprecated.
Created attachment 345914 [details] [review] GtkAboutDialog: We use gtk_show_uri_on_window() by default Not gtk_show_uri().
Created attachment 345915 [details] [review] GtkLinkButton: We use gtk_show_uri_on_window() by default Not gtk_show_uri().
Created attachment 345916 [details] [review] gtk: Ignore gtk_show_uri() deprecation warnings
Created attachment 345917 [details] [review] GtkMountOperation: We use gtk_show_uri_on_window() by default Not gtk_show_uri().
Created attachment 345918 [details] [review] Use gtk_show_uri_on_window() in GtkLabel Avoid the deprecated gtk_show_uri(), and allow activating link in sandboxed applications.
Review of attachment 345912 [details] [review]: LGTM
Review of attachment 345914 [details] [review]: Okay
Review of attachment 345915 [details] [review]: Okay.
Review of attachment 345916 [details] [review]: Fair enough. These widgets will likely be used by portals outside of the sandbox anyway, so it won't matter.
Review of attachment 345917 [details] [review]: Okay.
Review of attachment 345913 [details] [review]: Okay. I wonder if we should also mention that gtk_show_uri_on_window() is safe to use with regards to sandboxed applications, but I guess following the link to the function will be enough.
Review of attachment 345918 [details] [review]: Okay; thanks for updating my patch.
Created attachment 345952 [details] [review] docs: Advise to use gtk_show_uri_on_window() Instead of gtk_show_uri() which is now deprecated, and mention an additional benefit of doing so.
Attachment 345912 [details] pushed as c495ffb - docs: Fix reference to non-existent gtk_show_uri_on_parent() Attachment 345914 [details] pushed as f2febf7 - GtkAboutDialog: We use gtk_show_uri_on_window() by default Attachment 345915 [details] pushed as da02919 - GtkLinkButton: We use gtk_show_uri_on_window() by default Attachment 345916 [details] pushed as e4fbfde - gtk: Ignore gtk_show_uri() deprecation warnings Attachment 345917 [details] pushed as 72ac208 - GtkMountOperation: We use gtk_show_uri_on_window() by default Attachment 345918 [details] pushed as d93dd81 - Use gtk_show_uri_on_window() in GtkLabel Attachment 345952 [details] pushed as eca3518 - docs: Advise to use gtk_show_uri_on_window()
Also pushed the 5 that applied to master/GTK+ 4.x (all but the docs).