Skip to content

Commit

Permalink
more GTK Deprecation warnings removed
Browse files Browse the repository at this point in the history
  • Loading branch information
refdoc committed Nov 6, 2017
1 parent f25a989 commit d1b49ac
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 0 deletions.
5 changes: 5 additions & 0 deletions src/gnome2/main_menu.c
Expand Up @@ -114,8 +114,13 @@ on_help_contents_activate(GtkMenuItem *menuitem, gpointer user_data)
g_free(help_file);
#else
GError *error = NULL;
#if GTK_CHECK_VERSION(3, 22, 0)
gtk_show_uri_on_window(NULL, "ghelp:xiphos", gtk_get_current_event_time(),
&error);
#else
gtk_show_uri(NULL, "ghelp:xiphos", gtk_get_current_event_time(),
&error);
#endif
if (error != NULL) {
XI_warning(("%s", error->message));
g_error_free(error);
Expand Down
4 changes: 4 additions & 0 deletions src/gnome2/menu_popup.c
Expand Up @@ -2026,8 +2026,12 @@ void gui_menu_popup(XiphosHtml *html, const gchar *mod_name,

menu = _create_popup_menu(html, mod_name, d);
if (menu)
#if GTK_CHECK_VERSION(3, 22, 0)
gtk_menu_popup_at_pointer((GtkMenu *)menu, NULL);
#else
gtk_menu_popup((GtkMenu *)menu, NULL, NULL, NULL, NULL, 2,
gtk_get_current_event_time());
#endif
else
gui_generic_warning(_("No module in this pane."));
}

0 comments on commit d1b49ac

Please sign in to comment.