Hello community, here is the log from the commit of package mate-panel for openSUSE:Factory checked in at 2018-03-20 21:58:31 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Comparing /work/SRC/openSUSE:Factory/mate-panel (Old) and /work/SRC/openSUSE:Factory/.mate-panel.new (New) ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "mate-panel" Tue Mar 20 21:58:31 2018 rev:27 rq:587091 version:1.20.0 Changes: -------- --- /work/SRC/openSUSE:Factory/mate-panel/mate-panel.changes 2018-01-09 14:55:57.452026898 +0100 +++ /work/SRC/openSUSE:Factory/.mate-panel.new/mate-panel.changes 2018-03-20 21:58:59.468639229 +0100 @@ -1,0 +2,125 @@ +Wed Mar 14 21:04:47 UTC 2018 - [email protected] + +- Update summaries. Trim bias and filler wording from descriptions. + +------------------------------------------------------------------- +Fri Mar 9 19:10:07 UTC 2018 - [email protected] + +- Update to version 1.20.0: + * Require GTK+ 3.22 and GLib 2.50. + * status-notifier: Fix a crash on unknown signal name. + * Use GTK+3 bookmarks location for Places menu. + * doc: Remove some references to nonexistent stuff. + * Run dialogue: Add an option to reverse history view. + * Run dialogue: Fix wrong history len with max size 1. + * Run dialogue: Allow changing history size. + * Run dialogue: Fix wrong history order. + * status-notifier: Do not hide passive items. + * panel-menu-bar: Fix a build warning and some spacing. + * system-tray: Properly propagate orientation changes. + * workspace switcher: Handle GDK_SCROLL_SMOOTH and fix a build + warning. + * status-notifier: Fix handling of the icon-padding style + property. + * Simplify the panel description shown when switching panels with + the WM. + * status-notifier: Plug a memory leak. + * status-notifier-watcher: Allow re-registration of registered + items. + * Setup a custom icon. + * status-notifier: Plug a memory leak. + * menu: Remove incorrect code from the popup menu of a menuitem. + * status notifier: Follow the same menu theme as the rest of the + panel. + * clock: Drop deprecated gtk_size_group_set_ignore_hidden(). + * menu-button, action-button: Disconnect from GSettings when an + applet is removed. + * Avoid deprecated gdk_screen_get_number(). + * system tray: Fix hidden icons on image/transparent colour BG. + * clock: Fix hovering over timezone text, causes panel to scale + beyond screen limit. + * wncklet: Stop segfaults, warnings on removing the win-process + switcher, window-list. + * fish: Fix adding back after removal. + * Fish: Stop all warnings on removing when built in-process. + * Clock: Fix removal warnings when an in-process applet removed. + * clock: Stop a segfault on removing applet when built in-process. + * libmate-panel-applet: Fix typos in id->factory_id rename. + * libmate-panel-applet: Only declare + _panel_applet_shlib_factory() when needed. + * libmate-panel-applet: Fix an error in unregistering dbus object. + * libmate-panel-applet: Fix a build warning. + * libmate-panel-applet: Fix introspection. + * libmate-panel-applet: Unown the bus name and unregister the + D-Bus object. + * libmate-panel-applet: Include a dummy variable in factory for + certian applets. + * libmate-panel-applet: Fix bg rendering for in-process applets. + * libpanel-applet/panel-applet.h: Rename id to factory_id for + factory. + * limatepanel-applet: Add panel-applet-private.h. + * Don't use GtkPlug/GtkSocket for in process applets. + * Make it possible to get an applet widget. + * libpanel-applet: Add panel_applet_factory_get_applet_widget. + * libpanel-applet: Return process type and applet uid. + * libpanel-applet: Store factories in hash table. + * libpanel-applet: Delay GtkPlug creation. + * libpanel-applet: Add process type to private data. + * libpanel-applet: Remove out_process from panel_applet_factory_main(). + * Avoid deprecated gdk_screen_get_width/height(), + gdk_screen_get_n_monitors(). + * fish: Fix applet opening as a thin line when built in-process. + * Forces a window scale of 1 for the panel instead of using the + default or user configured scale. + * Avoid deprecated gdk_screen_get_monitor_, + gdk_screen_make_display_name(), gdk_display_get_screen() + functions. + * Don't use deprecated gtk_show_uri(). + * An implementation of WidthOfScreen and HeightOfScreen. + * Keep the right icons on bottom still displaying right when the + resolution change larger. + * wncklet: Disconnect signals by data on destroy. + * Clock: Don't check variables that can never be < 0 for < 0. + * status-notifier: Hide mate-polkit icon if passive. + * Apply a position fix on popup to GTK+ 3.20 and earlier. + * Stop panel collapse left on adding certain out-of-process + applets. + * panel-context-menu: Add confirmation dialogue to the panel + reset option. + * Add an option to the context menu to reset the panel. + * Bump the minimum required libwnck version to 3.4.6. + * status-notifier: Don't crash if the tooltip has the wrong type. + * status-notifier: Don't crash if the menu layout has the wrong + type. + * Fix rendering of radio buttons in status notifier. + * panel-run-dialog: Fix a segfault when the application list is + enabled. + * Get focus when displaying the "applet broken" dialogue. + * Update the workspace switcher properties dialogue. + * Simplify some code. + * status-notifier: Properly handle the NULL case for items. + * status-notifier: Handle wrong-size icons called by path. + * status-notifier: Load icons specified by path. + * Fix failures to load icons when the application calls for a + path and not an icon name. + * Fix a build warning: "toplevel_configure_event" defined but not + used. + * Fix a build warning: "GLIB_VERSION_MIN_REQUIRED" redefined. + * status-notifier: Fix failure to show an icon for missing icon. + * Spelling: apps, … spaced comma. + * Support panel auto-scaling for HiDPI displays. + * Add gir for mate_panel_applet_set_size_hints(). + * panel-stock-icons.c: Fix warnings in ~/.xsession-errors. + * Fix run dialogue show-program-list enabling. + * panel-run-dialog: Fix a build warning about incompatible type. + * workspace-switcher: Restore border width and spacing in the + Preferences dialogue. + * context menu: Add a separator before the Reset Panel menu item. + * background: Reword a warning about an unsupported + background-image value. + * Set the "document-properties" icon in "Edit Menus". + * Update translations. +- Add mate-panel-gtk-3.20.patch: Restore GLib 2.48 and GTK+ 3.20 + support. + +------------------------------------------------------------------- Old: ---- mate-panel-1.18.7.tar.xz New: ---- mate-panel-1.20.0.tar.xz mate-panel-gtk-3.20.patch ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ mate-panel.spec ++++++ --- /var/tmp/diff_new_pack.RmHpKi/_old 2018-03-20 21:59:00.364606970 +0100 +++ /var/tmp/diff_new_pack.RmHpKi/_new 2018-03-20 21:59:00.368606826 +0100 @@ -19,19 +19,21 @@ %define soname libmate-panel-applet-4 %define sover 1 %define typelib typelib-1_0-MatePanelApplet-4_0 -%define _version 1.18 +%define _version 1.20 Name: mate-panel -Version: 1.18.7 +Version: 1.20.0 Release: 0 Summary: MATE Desktop Panel -License: GPL-2.0+ +License: GPL-2.0-or-later Group: System/GUI/Other Url: https://mate-desktop.org/ Source: http://pub.mate-desktop.org/releases/%{_version}/%{name}-%{version}.tar.xz Source1: %{name}-branding.gschema.override.in Source2: baselibs.conf # PATCH-FIX-OPENSUSE mate-panel-layouts-suse.patch [email protected] -- Correct missing elements. -Patch0: %{name}-layouts-suse.patch +Patch0: mate-panel-layouts-suse.patch +# PATCH-FEATURE-OPENSUSE mate-panel-gtk-3.20.patch -- Restore GLib 2.48 and GTK+ 3.20 support. +Patch1: mate-panel-gtk-3.20.patch BuildRequires: fdupes BuildRequires: hicolor-icon-theme BuildRequires: libxml2-python @@ -43,10 +45,10 @@ BuildRequires: pkgconfig(NetworkManager) BuildRequires: pkgconfig(dbus-glib-1) BuildRequires: pkgconfig(dconf) >= 0.13.4 -BuildRequires: pkgconfig(gio-2.0) -BuildRequires: pkgconfig(glib-2.0) +BuildRequires: pkgconfig(gio-2.0) >= 2.48 +BuildRequires: pkgconfig(glib-2.0) >= 2.48 BuildRequires: pkgconfig(gobject-introspection-1.0) -BuildRequires: pkgconfig(gtk+-3.0) >= 3.14 +BuildRequires: pkgconfig(gtk+-3.0) >= 3.20 BuildRequires: pkgconfig(ice) BuildRequires: pkgconfig(libmate-menu) BuildRequires: pkgconfig(librsvg-2.0) @@ -64,13 +66,13 @@ Obsoletes: mate-panel-matecomponent-support %description -This package contains MATE Desktop Panel. The panel is an -easy-to-use and functional interface to manage your desktop, start -programs, and organise access to your data. +This package contains the MATE Desktop Panel. The panel is an +interface to manage the desktop, launch applications, and organise +access to data. %package branding-upstream -Summary: The MATE Desktop Panel -- Upstream default layout -License: GPL-2.0+ +Summary: Upstream default layout for the MATE desktop panel +License: GPL-2.0-or-later Group: System/GUI/Other Requires: %{name} = %{version} Supplements: packageand(%{name}:branding-upstream) @@ -85,48 +87,49 @@ %description branding-upstream This package contains the MATE Desktop Panel. The panel is an -easy-to-use and functional interface to manage your desktop, start -programs, and organise access to your data. +interface to manage the desktop, launch applications, and organise +access to data. This package contains the upstream default layout for MATE Panel. %package -n %{soname}-%{sover} Summary: MATE Panel Applet Library -- matecomponent-based library -License: LGPL-2.1+ +License: LGPL-2.1-or-later Group: System/Libraries %description -n %{soname}-%{sover} -This package contains MATE Desktop Panel. The panel is an -easy-to-use and functional interface to manage your desktop, start -programs, and organise access to your data. +This package contains the MATE Desktop Panel. The panel is an +interface to manage the desktop, launch applications, and organise +access to data. %package -n %{typelib} -Summary: MATE Panel Applet Library typelib -License: GPL-2.0+ +Summary: Introspection bindings for the MATE panel applet library +License: GPL-2.0-or-later Group: System/GUI/Other %description -n %{typelib} -This package contains MATE Desktop Panel. The panel is an -easy-to-use and functional interface to manage your desktop, start -programs, and organise access to your data. +This package contains the MATE Desktop Panel. The panel is an +interface to manage the desktop, launch applications, and organise +access to data. %package devel -Summary: MATE Panel Applet Library -- Development Files -License: GPL-2.0+ +Summary: Development files for the MATE panel applet library +License: GPL-2.0-or-later Group: Development/Libraries/Other Requires: %{soname}-%{sover} = %{version} Requires: %{typelib} = %{version} %description devel This package contains the MATE Desktop Panel. The panel is an -easy-to-use and functional interface to manage your desktop, start -programs, and organise access to your data. +interface to manage the desktop, launch applications, and organise +access to data. %lang_package %prep %setup -q %patch0 -p1 +%patch1 -p1 cp -a %{SOURCE1} zz-mate-panel-upream-branding.gschema.override %build @@ -150,13 +153,14 @@ # And install schema override file to get it applied. mkdir -p %{buildroot}%{_datadir}/glib-2.0/schemas/ -install -pm 0644 zz-mate-panel-upream-branding.gschema.override %{buildroot}%{_datadir}/glib-2.0/schemas/ +install -pm 0644 zz-mate-panel-upream-branding.gschema.override \ + %{buildroot}%{_datadir}/glib-2.0/schemas/ %post -n %{soname}-%{sover} -p /sbin/ldconfig %postun -n %{soname}-%{sover} -p /sbin/ldconfig -%if 0%{?suse_version} <= 1320 +%if 0%{?suse_version} < 1500 %post %desktop_database_post %icon_theme_cache_post @@ -175,7 +179,12 @@ %endif %files -%doc ChangeLog README COPYING +%if 0%{?suse_version} >= 1500 +%license COPYING +%else +%doc COPYING +%endif +%doc ChangeLog README %{_mandir}/man?/mate-panel.?%{?ext_man} %{_mandir}/man?/mate-panel-test-applets.?%{?ext_man} %{_mandir}/man?/mate-desktop-item-edit.?%{?ext_man} ++++++ mate-panel-1.18.7.tar.xz -> mate-panel-1.20.0.tar.xz ++++++ ++++ 131353 lines of diff (skipped) ++++++ mate-panel-gtk-3.20.patch ++++++ diff -paur a/applets/clock/clock.c b/applets/clock/clock.c --- a/applets/clock/clock.c 2018-02-02 15:15:23.000000000 +0300 +++ b/applets/clock/clock.c 2018-03-10 03:04:57.188309840 +0300 @@ -874,9 +874,17 @@ position_calendar_popup (ClockData *cd) screen = gtk_window_get_screen (GTK_WINDOW (cd->calendar_popup)); display = gdk_screen_get_display (screen); +#if GTK_CHECK_VERSION (3, 22, 0) n = gdk_display_get_n_monitors (display); +#else + n = gdk_screen_get_n_monitors (screen); +#endif for (i = 0; i < n; i++) { +#if GTK_CHECK_VERSION (3, 22, 0) gdk_monitor_get_geometry (gdk_display_get_monitor (display, i), &monitor); +#else + gdk_screen_get_monitor_geometry (screen, i, &monitor); +#endif if (x >= monitor.x && x <= monitor.x + monitor.width && y >= monitor.y && y <= monitor.y + monitor.height) { found_monitor = TRUE; diff -paur a/applets/clock/clock-utils.c b/applets/clock/clock-utils.c --- a/applets/clock/clock-utils.c 2018-02-02 15:15:23.000000000 +0300 +++ b/applets/clock/clock-utils.c 2018-03-10 03:02:42.447211163 +0300 @@ -72,9 +72,13 @@ clock_utils_display_help (GtkWidget *wi uri = g_strdup_printf ("help:%s/%s", doc_id, link_id); else uri = g_strdup_printf ("help:%s", doc_id); - +#if GTK_CHECK_VERSION (3, 22, 0) gtk_show_uri_on_window (NULL, uri, gtk_get_current_event_time (), &error); +#else + gtk_show_uri (gtk_widget_get_screen (widget), uri, + gtk_get_current_event_time (), &error); +#endif g_free (uri); if (error && diff -paur a/applets/fish/fish.c b/applets/fish/fish.c --- a/applets/fish/fish.c 2018-02-02 15:15:23.000000000 +0300 +++ b/applets/fish/fish.c 2018-03-10 03:05:25.188538764 +0300 @@ -153,8 +153,13 @@ static void show_help(FishApplet* fish, else uri = g_strdup_printf ("help:%s", FISH_HELP_DOC); +#if GTK_CHECK_VERSION (3, 22, 0) gtk_show_uri_on_window (NULL, uri, gtk_get_current_event_time (), &error); +#else + gtk_show_uri (gtk_widget_get_screen (GTK_WIDGET (fish)), uri, + gtk_get_current_event_time (), &error); +#endif g_free (uri); if (error && diff -paur a/applets/notification_area/main.c b/applets/notification_area/main.c --- a/applets/notification_area/main.c 2018-02-02 15:15:23.000000000 +0300 +++ b/applets/notification_area/main.c 2018-03-10 03:02:42.471211358 +0300 @@ -111,7 +111,11 @@ static void help_cb(GtkAction* action, N #define NA_HELP_DOC "mate-user-guide" uri = g_strdup_printf("help:%s/%s", NA_HELP_DOC, "panels-notification-area"); +#if GTK_CHECK_VERSION (3, 22, 0) gtk_show_uri_on_window (NULL, uri, gtk_get_current_event_time (), &error); +#else + gtk_show_uri(gtk_widget_get_screen(GTK_WIDGET(applet)), uri, gtk_get_current_event_time(), &error); +#endif g_free(uri); if (error && g_error_matches (error, G_IO_ERROR, G_IO_ERROR_CANCELLED)) diff -paur a/applets/notification_area/status-notifier/sn-dbus-menu.c b/applets/notification_area/status-notifier/sn-dbus-menu.c --- a/applets/notification_area/status-notifier/sn-dbus-menu.c 2018-02-02 15:15:23.000000000 +0300 +++ b/applets/notification_area/status-notifier/sn-dbus-menu.c 2018-03-10 03:06:02.788819185 +0300 @@ -188,9 +188,11 @@ get_layout_cb (GObject *source_obje g_hash_table_remove_all (menu->items); layout_parse (menu, layout, GTK_MENU (menu)); +#if GTK_CHECK_VERSION (3, 22, 0) /* Reposition menu to accomodate any size changes */ /* Menu size never changes with GTK 3.20 or earlier */ gtk_menu_reposition(GTK_MENU(menu)); +#endif g_variant_unref (layout); } diff -paur a/applets/notification_area/status-notifier/sn-item.c b/applets/notification_area/status-notifier/sn-item.c --- a/applets/notification_area/status-notifier/sn-item.c 2018-02-02 15:15:23.000000000 +0300 +++ b/applets/notification_area/status-notifier/sn-item.c 2018-03-10 03:09:23.382076703 +0300 @@ -182,6 +182,49 @@ sn_item_get_action_coordinates (SnItem * *x += width; } +#if !GTK_CHECK_VERSION (3, 22, 0) +static void +sn_item_popup_menu_position_func (GtkMenu *menu, + int *x, + int *y, + gboolean *push_in, + gpointer widget) +{ + GtkAllocation widget_alloc; + GtkRequisition menu_req; + GdkWindow *window; + GdkScreen *screen; + int monitor_num; + GdkRectangle monitor; + + gtk_widget_get_allocation (widget, &widget_alloc); + gtk_widget_get_preferred_size (GTK_WIDGET (menu), &menu_req, NULL); + + window = gtk_widget_get_window (widget); + gdk_window_get_origin (window, x, y); + + *x += widget_alloc.x; + *y += widget_alloc.y; + + screen = gtk_widget_get_screen (widget); + monitor_num = gdk_screen_get_monitor_at_point (screen, *x, *y); + gdk_screen_get_monitor_geometry (screen, monitor_num, &monitor); + + /* put the menu on the left if we can't put it on the right */ + if (*x + menu_req.width > monitor.x + monitor.width) + *x -= menu_req.width - widget_alloc.width; + /* and push it back in if all else failed */ + if (*x < monitor.x) + *x = monitor.x; + + /* put the menu above if we can't put it below */ + if (*y + widget_alloc.height + menu_req.height > monitor.y + monitor.height) + *y -= menu_req.height; + else + *y += widget_alloc.height; +} +#endif + static gboolean sn_item_button_press_event (GtkWidget *widget, GdkEventButton *event) @@ -208,10 +251,16 @@ sn_item_button_press_event (GtkWidget { if (priv->menu != NULL) { +#if GTK_CHECK_VERSION (3, 22, 0) gtk_menu_popup_at_widget (priv->menu, widget, GDK_GRAVITY_SOUTH_WEST, GDK_GRAVITY_NORTH_WEST, (GdkEvent *) event); +#else + gtk_menu_popup (priv->menu, NULL, NULL, + sn_item_popup_menu_position_func, widget, + event->button, event->time); +#endif /*Fix positioning if size changed since last shown*/ gtk_menu_reposition(priv->menu); } @@ -240,10 +289,26 @@ sn_item_popup_menu (GtkWidget *widget) if (priv->menu != NULL) { +#if GTK_CHECK_VERSION (3, 22, 0) gtk_menu_popup_at_widget (priv->menu, widget, GDK_GRAVITY_SOUTH_WEST, GDK_GRAVITY_NORTH_WEST, NULL); +#else + unsigned int button = 0; + guint32 active_time = GDK_CURRENT_TIME; + GdkEvent *event = gtk_get_current_event (); + + if (event) + { + gdk_event_get_button (event, &button); + active_time = gdk_event_get_time (event); + } + + gtk_menu_popup (priv->menu, NULL, NULL, + sn_item_popup_menu_position_func, widget, + button, active_time); +#endif /*Fix positioning if size changed since last shown*/ gtk_menu_reposition(priv->menu); } diff -paur a/applets/wncklet/wncklet.c b/applets/wncklet/wncklet.c --- a/applets/wncklet/wncklet.c 2018-02-02 15:15:23.000000000 +0300 +++ b/applets/wncklet/wncklet.c 2018-03-10 03:09:49.238248055 +0300 @@ -49,8 +49,12 @@ void wncklet_display_help(GtkWidget* wid uri = g_strdup_printf("help:%s/%s", doc_id, link_id); else uri = g_strdup_printf("help:%s", doc_id); - +#if GTK_CHECK_VERSION (3, 22, 0) gtk_show_uri_on_window (NULL, uri, gtk_get_current_event_time (), &error); +#else + gtk_show_uri (gtk_widget_get_screen (widget), uri, + gtk_get_current_event_time (), &error); +#endif g_free(uri); if (error && g_error_matches(error, G_IO_ERROR, G_IO_ERROR_CANCELLED)) diff -paur a/configure.ac b/configure.ac --- a/configure.ac 2018-02-02 16:04:49.000000000 +0300 +++ b/configure.ac 2018-03-10 03:38:52.503567361 +0300 @@ -56,13 +56,13 @@ LT_LIB_M LIBMATE_DESKTOP_REQUIRED=1.17.0 GDK_PIXBUF_REQUIRED=2.7.1 PANGO_REQUIRED=1.15.4 -GLIB_REQUIRED=2.50.0 +GLIB_REQUIRED=2.48.0 LIBMATE_MENU_REQUIRED=1.10.0 CAIRO_REQUIRED=1.0.0 DBUS_GLIB_REQUIRED=0.80 DCONF_REQUIRED=0.13.4 LIBRSVG_REQUIRED=2.36.2 -GTK_REQUIRED=3.22.0 +GTK_REQUIRED=3.20.0 LIBWNCK_REQUIRED=3.4.6 WEATHER_REQUIRED=1.17.0 diff -paur a/mate-panel/libpanel-util/panel-show.c b/mate-panel/libpanel-util/panel-show.c --- a/mate-panel/libpanel-util/panel-show.c 2018-02-02 15:15:24.000000000 +0300 +++ b/mate-panel/libpanel-util/panel-show.c 2018-03-10 03:10:13.894413118 +0300 @@ -177,9 +177,11 @@ gboolean panel_show_uri(GdkScreen* scree { return panel_show_caja_search_uri(screen, uri, timestamp, error); } - +#if GTK_CHECK_VERSION (3, 22, 0) gtk_show_uri_on_window (NULL, uri,timestamp, &local_error); - +#else + gtk_show_uri (screen, uri, timestamp, &local_error); +#endif return _panel_show_handle_error(uri, screen, local_error, error); } @@ -282,8 +284,11 @@ panel_show_help (GdkScreen *screen, uri = g_strdup_printf ("help:%s/%s", doc, link); else uri = g_strdup_printf ("help:%s", doc); - +#if GTK_CHECK_VERSION (3, 22, 0) gtk_show_uri_on_window (NULL, uri, gtk_get_current_event_time (), &local_error); +#else + gtk_show_uri (screen, uri, gtk_get_current_event_time (), &local_error); +#endif g_free (uri); return _panel_show_help_handle_error (doc, screen, local_error, error); diff -paur a/mate-panel/panel-multiscreen.c b/mate-panel/panel-multiscreen.c --- a/mate-panel/panel-multiscreen.c 2018-02-02 15:15:24.000000000 +0300 +++ b/mate-panel/panel-multiscreen.c 2018-03-10 03:10:38.206577394 +0300 @@ -208,11 +208,19 @@ panel_multiscreen_get_gdk_monitors_for_s int i; display = gdk_screen_get_display (screen); +#if GTK_CHECK_VERSION (3, 22, 0) num_monitors = gdk_display_get_n_monitors (display); +#else + num_monitors = gdk_screen_get_n_monitors (screen); +#endif geometries = g_new (GdkRectangle, num_monitors); for (i = 0; i < num_monitors; i++) +#if GTK_CHECK_VERSION (3, 22, 0) gdk_monitor_get_geometry (gdk_display_get_monitor (display, i), &(geometries[i])); +#else + gdk_screen_get_monitor_geometry (screen, i, &(geometries[i])); +#endif *monitors_ret = num_monitors; *geometries_ret = geometries; diff -paur a/mate-panel/xstuff.c b/mate-panel/xstuff.c --- a/mate-panel/xstuff.c 2018-02-02 15:15:24.000000000 +0300 +++ b/mate-panel/xstuff.c 2018-03-10 03:11:33.674957452 +0300 @@ -335,7 +335,11 @@ xstuff_zoom_animate (GtkWidget *widget, GdkScreen *gscreen; GdkRectangle rect, dest; GtkAllocation allocation; +#if GTK_CHECK_VERSION (3, 22, 0) GdkMonitor *monitor; +#else + int monitor_num; +#endif GdkDisplay *display; if (opt_rect) @@ -359,10 +363,16 @@ xstuff_zoom_animate (GtkWidget *widget, rect.width, rect.height, pixbuf, orientation); else { +#if GTK_CHECK_VERSION (3, 22, 0) display = gdk_screen_get_display (gscreen); monitor = gdk_display_get_monitor_at_window (display, gtk_widget_get_window (widget)); gdk_monitor_get_geometry (monitor, &dest); +#else + monitor_num = gdk_screen_get_monitor_at_window (gscreen, + gtk_widget_get_window (widget)); + gdk_screen_get_monitor_geometry (gscreen, monitor_num, &dest); +#endif draw_zoom_animation (gscreen, rect.x, rect.y, rect.width, rect.height,
