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 780507 - Use gtk_show_uri_on_window instead of deprecated gtk_show_uri
Use gtk_show_uri_on_window instead of deprecated gtk_show_uri
Status: RESOLVED FIXED
Product: gnome-documents
Classification: Core
Component: general
3.24.x
Other All
: Normal normal
: ---
Assigned To: GNOME documents maintainer(s)
GNOME documents maintainer(s)
Depends on:
Blocks:
 
 
Reported: 2017-03-24 17:45 UTC by Debarshi Ray
Modified: 2017-03-28 08:37 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
Use gtk_show_uri_on_window instead of deprecated gtk_show_uri (3.34 KB, patch)
2017-03-24 17:46 UTC, Debarshi Ray
none Details | Review
Use gtk_show_uri_on_window instead of deprecated gtk_show_uri (3.44 KB, patch)
2017-03-27 16:08 UTC, Debarshi Ray
committed Details | Review

Description Debarshi Ray 2017-03-24 17:45:18 UTC
gtk_show_uri is deprecated and its replacement gtk_show_uri_on_window is more sandbox-friendly.
Comment 1 Debarshi Ray 2017-03-24 17:46:50 UTC
Created attachment 348663 [details] [review]
Use gtk_show_uri_on_window instead of deprecated gtk_show_uri
Comment 2 Cosimo Cecchi 2017-03-26 08:16:39 UTC
Review of attachment 348663 [details] [review]:

Thanks, this looks good with one comment.

::: src/selections.js
@@ +993,3 @@
             function(urn) {
                 let doc = Application.documentManager.getItemById(urn);
+                let toplevel = Application.application.get_windows()[0];

Instead of this, can you use gtk_widget_get_toplevel() with the widget?
Comment 3 Debarshi Ray 2017-03-27 16:08:20 UTC
(In reply to Cosimo Cecchi from comment #2)
> Review of attachment 348663 [details] [review] [review]:
> 
> Thanks, this looks good with one comment.
> 
> ::: src/selections.js
> @@ +993,3 @@
>              function(urn) {
>                  let doc = Application.documentManager.getItemById(urn);
> +                let toplevel = Application.application.get_windows()[0];
> 
> Instead of this, can you use gtk_widget_get_toplevel() with the widget?

Of course.
Comment 4 Debarshi Ray 2017-03-27 16:08:36 UTC
Created attachment 348811 [details] [review]
Use gtk_show_uri_on_window instead of deprecated gtk_show_uri
Comment 5 Cosimo Cecchi 2017-03-27 17:43:35 UTC
Review of attachment 348811 [details] [review]:

Looks good.
Comment 6 Debarshi Ray 2017-03-28 08:37:38 UTC
Comment on attachment 348811 [details] [review]
Use gtk_show_uri_on_window instead of deprecated gtk_show_uri

Pushed to master.