Hello community,

here is the log from the commit of package virt-viewer for openSUSE:Factory 
checked in at 2014-07-02 15:05:21
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/virt-viewer (Old)
 and      /work/SRC/openSUSE:Factory/.virt-viewer.new (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Package is "virt-viewer"

Changes:
--------
--- /work/SRC/openSUSE:Factory/virt-viewer/virt-viewer.changes  2014-06-16 
21:37:22.000000000 +0200
+++ /work/SRC/openSUSE:Factory/.virt-viewer.new/virt-viewer.changes     
2014-07-02 15:05:36.000000000 +0200
@@ -1,0 +2,17 @@
+Tue Jul  1 13:12:17 MDT 2014 - [email protected]
+
+- Upstream bug fixes
+  53970bee-remove-warning-when-removing-display.patch
+  53975d94-fix-tiny-windows-for-secondary-displays-in-gtk2-build.patch
+  5398b944-take-zoom-level-into-account-for-display-limits.patch
+  5398b971-fix-tiny-window-when-resetting-zoom-factor-in-gtk2-build.patch
+  53a8716d-fix-un-shrinkable-displays-on-windows-guests.patch
+
+-------------------------------------------------------------------
+Tue Jul  1 16:19:17 UTC 2014 - [email protected]
+
+- Switch build to gtk3 for SLE12 and openSUSE 13.2.
+- Update windows-keycombo.patch and netware-keycombo.patch to build
+  with GTK 3.
+
+-------------------------------------------------------------------

New:
----
  53970bee-remove-warning-when-removing-display.patch
  53975d94-fix-tiny-windows-for-secondary-displays-in-gtk2-build.patch
  5398b944-take-zoom-level-into-account-for-display-limits.patch
  5398b971-fix-tiny-window-when-resetting-zoom-factor-in-gtk2-build.patch
  53a8716d-fix-un-shrinkable-displays-on-windows-guests.patch

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Other differences:
------------------
++++++ virt-viewer.spec ++++++
--- /var/tmp/diff_new_pack.1Y8X2Y/_old  2014-07-02 15:05:37.000000000 +0200
+++ /var/tmp/diff_new_pack.1Y8X2Y/_new  2014-07-02 15:05:37.000000000 +0200
@@ -16,6 +16,12 @@
 #
 
 
+%if %suse_version >= 1315
+%define gtk_arg --with-gtk=3.0
+%else
+%define gtk_arg --with-gtk=2.0
+%endif
+
 Name:           virt-viewer
 Summary:        Virtual Machine Viewer
 License:        GPL-2.0+
@@ -35,22 +41,35 @@
 Patch9:         5322b929-fix-building-with-older-spice-gtk.patch
 Patch10:        538df41a-set-freed-variables-to-null.patch
 Patch11:        5396d3dd-dont-connect-to-localhost-when-using-direct.patch
-Patch20:        netcat.patch
-Patch21:        windows-keycombo.patch
-Patch22:        netware-keycombo.patch
-Patch23:        report-error.patch
-Patch24:        virtview-desktop.patch
-Patch50:        spice-gtk.patch
+Patch12:        53970bee-remove-warning-when-removing-display.patch
+Patch13:        
53975d94-fix-tiny-windows-for-secondary-displays-in-gtk2-build.patch
+Patch14:        5398b944-take-zoom-level-into-account-for-display-limits.patch
+Patch15:        
5398b971-fix-tiny-window-when-resetting-zoom-factor-in-gtk2-build.patch
+Patch16:        53a8716d-fix-un-shrinkable-displays-on-windows-guests.patch
+Patch50:        netcat.patch
+Patch51:        windows-keycombo.patch
+Patch52:        netware-keycombo.patch
+Patch53:        report-error.patch
+Patch54:        virtview-desktop.patch
+Patch55:        spice-gtk.patch
 ExclusiveArch:  %ix86 x86_64 s390x
 BuildRoot:      %{_tmppath}/%{name}-%{version}-build
 
 BuildRequires:  automake
+%if %suse_version >= 1315
+BuildRequires:  pkgconfig(gtk+-3.0)
+%else
 BuildRequires:  gtk2-devel
+%endif
 BuildRequires:  libvirt-devel >= 0.9.7
 BuildRequires:  libxml2-devel
 %if %suse_version > 1140
+%if %suse_version >= 1315
+BuildRequires:  pkgconfig(gtk-vnc-2.0)
+%else
 BuildRequires:  gtk-vnc2-devel
 %endif
+%endif
 BuildRequires:  gtk-vnc-devel >= 0.3.8
 BuildRequires:  libglade2-devel
 %if %suse_version > 1130
@@ -84,17 +103,22 @@
 %patch9 -p1
 %patch10 -p1
 %patch11 -p1
-%patch20 -p1
-%patch21 -p1
-%patch22 -p1
-%patch23 -p1
-%patch24 -p1
+%patch12 -p1
+%patch13 -p1
+%patch14 -p1
+%patch15 -p1
+%patch16 -p1
 %patch50 -p1
+%patch51 -p1
+%patch52 -p1
+%patch53 -p1
+%patch54 -p1
+%patch55 -p1
 
 %build
 echo "suse_version = %suse_version"
 %if %suse_version >= 1230
-%configure --with-spice-gtk --with-gtk=2.0 --disable-update-mimedb
+%configure --with-spice-gtk %{gtk_arg} --disable-update-mimedb
 %else
 %configure --with-gtk=2.0 --disable-update-mimedb 
GTKVNC_CFLAGS=-I/usr/include/gtk-vnc-1.0 GTKVNC_LIBS=-lgtk-vnc-1.0
 %endif

++++++ 53970bee-remove-warning-when-removing-display.patch ++++++
Subject: Remove warning when removing display
From: Marc-AndrĂ© Lureau [email protected] Tue Jun 10 14:25:16 2014 
+0300
Date: Tue Jun 10 15:45:18 2014 +0200:
Git: 78c9612257b95ee924ad0b13372106bde3d851f8

Some display have no associated window (for ex, if it doesn't fit
on client monitors).

(remote-viewer:22275): remote-viewer-CRITICAL **: 
virt_viewer_window_set_display: assertion `VIRT_VIEWER_IS_WINDOW(self)' failed

(remote-viewer:22275): remote-viewer-CRITICAL **: 
virt_viewer_app_remove_nth_window: assertion `win != NULL' failed

https://bugzilla.redhat.com/show_bug.cgi?id=1107518

Index: virt-viewer-0.6.0/src/virt-viewer-app.c
===================================================================
--- virt-viewer-0.6.0.orig/src/virt-viewer-app.c
+++ virt-viewer-0.6.0/src/virt-viewer-app.c
@@ -858,8 +858,10 @@ virt_viewer_app_display_removed(VirtView
     gtk_widget_hide(GTK_WIDGET(display));
     g_object_get(display, "nth-display", &nth, NULL);
     win = virt_viewer_app_get_nth_window(self, nth);
-    virt_viewer_window_set_display(win, NULL);
+    if (!win)
+        return;
 
+    virt_viewer_window_set_display(win, NULL);
     if (nth != 0)
         virt_viewer_app_remove_nth_window(self, nth);
 }
++++++ 53975d94-fix-tiny-windows-for-secondary-displays-in-gtk2-build.patch 
++++++
Subject: Fix tiny windows for secondary displays in gtk2 build
From: Jonathon Jongsma [email protected] Tue Jun 10 11:31:25 2014 -0500
Date: Tue Jun 10 14:33:40 2014 -0500:
Git: 6edde57862ac30e74ce6412c93a2fa925ae4ea67

When enabling a new display on linux guests, the new window would be tiny
(50x50) and zoomed way out. This was caused by the fact that when the display
widget received the 'map' event, it unconditionally cleared the 'dirty' flag,
which meant that it would only request 50x50 size. This behavior was intended to
fix a bug on the windows client which wprevented windows from resized smaller
than the guest display resolution. Unfortunately, due to the timing of the 'map'
and allocate events, the widget became very small.

Instead of clearing the 'dirty' flag directly when a widget is mapped, we
now queue a resize event, which will guarantee that the widget attains its
desired size and will then clear its dirty flag (allowing it to be resized).
Testing on windows indicates that this fix still solves the 'unshrinkable
window' problem while also preventing the tiny secondary display bug.

Resolves: rhbz#1104064

Index: virt-viewer-0.6.0/src/virt-viewer-display.c
===================================================================
--- virt-viewer-0.6.0.orig/src/virt-viewer-display.c
+++ virt-viewer-0.6.0/src/virt-viewer-display.c
@@ -441,7 +441,7 @@ virt_viewer_display_map(GtkWidget *widge
 {
     GTK_WIDGET_CLASS(virt_viewer_display_parent_class)->map(widget);
 
-    virt_viewer_display_make_resizable(VIRT_VIEWER_DISPLAY(widget));
+    virt_viewer_display_queue_resize(VIRT_VIEWER_DISPLAY(widget));
 }
 
 #else
++++++ 5398b944-take-zoom-level-into-account-for-display-limits.patch ++++++
Subject: window: take zoom-level into account for display limits
From: Marc-AndrĂ© Lureau [email protected] Wed Jun 11 20:56:39 2014 
+0300
Date: Wed Jun 11 22:17:08 2014 +0200:
Git: d1b2840997f47f0c39c16b6ffc7c2ae5e7934e01

Fixes guest can not be resized to expected window size after zoom out.

https://bugzilla.redhat.com/show_bug.cgi?id=1105528

Index: virt-viewer-0.6.0/src/virt-viewer-window.c
===================================================================
--- virt-viewer-0.6.0.orig/src/virt-viewer-window.c
+++ virt-viewer-0.6.0/src/virt-viewer-window.c
@@ -411,8 +411,8 @@ virt_viewer_window_resize(VirtViewerWind
     int width, height;
     double desktopAspect;
     double screenAspect;
-    guint desktopWidth;
-    guint desktopHeight;
+    guint desktopWidth, display_width;
+    guint desktopHeight, display_height;
     VirtViewerWindowPrivate *priv = self->priv;
 
     if (!priv->auto_resize || priv->fullscreen)
@@ -439,8 +439,11 @@ virt_viewer_window_resize(VirtViewerWind
     desktopAspect = (double)desktopWidth / (double)desktopHeight;
     screenAspect = (double)fullscreen.width / (double)fullscreen.height;
 
-    if ((desktopWidth > fullscreen.width) ||
-        (desktopHeight > fullscreen.height)) {
+    display_width = desktopWidth * priv->zoomlevel / 100.0;
+    display_height = desktopHeight * priv->zoomlevel / 100.0;
+
+    if ((display_width > fullscreen.width) ||
+        (display_height > fullscreen.height)) {
         /* Doesn't fit native res, so go as large as possible
            maintaining aspect ratio */
         if (screenAspect > desktopAspect) {
@@ -450,6 +453,8 @@ virt_viewer_window_resize(VirtViewerWind
             width = fullscreen.width;
             height = fullscreen.width / desktopAspect;
         }
+        width *= 100.0 / priv->zoomlevel;
+        height *= 100.0 / priv->zoomlevel;
     } else {
         width = desktopWidth;
         height = desktopHeight;
++++++ 5398b971-fix-tiny-window-when-resetting-zoom-factor-in-gtk2-build.patch 
++++++
Subject: Fix tiny window when resetting zoom factor in gtk2 build
From: Jonathon Jongsma [email protected] Wed Jun 11 13:09:30 2014 -0500
Date: Wed Jun 11 15:17:53 2014 -0500:
Git: b707b4524ff12ae1c2c3deff0e8c3f0d098f0503

rhbz#1104064 had a couple of symptoms. The first was fixed in
6edde57862ac30e74ce6412c93a2fa925ae4ea67.

The second symptom is that displays could also become tiny when clicking 'View >
Zoom > Normal Size'. This was because VirtViewerDisplay returned early from
_display_set_zoom_level() if the zoom level was being set to the current zoom
setting. However, the calling function (_window_set_zoom_level()) also tries to
queue a resize event for itself after setting the zoom level on the display. If
the display doesn't queue a resize event for itself, its size request will only
be 50x50 during the window resize negotiation. This causes the display to become
tiny and zoomed out. Queueing a resize on the display widget ensures that it
will request the proper size during the next allocation.

Index: virt-viewer-0.6.0/src/virt-viewer-display.c
===================================================================
--- virt-viewer-0.6.0.orig/src/virt-viewer-display.c
+++ virt-viewer-0.6.0/src/virt-viewer-display.c
@@ -592,12 +592,19 @@ void virt_viewer_display_set_zoom_level(
     if (zoom > MAX_ZOOM_LEVEL)
         zoom = MAX_ZOOM_LEVEL;
 
+    // For the gtk2 build, we need to queue a resize even if the zoom level
+    // hasn't changed.  This is due to the fact that VirtViewerWindow will 
queue
+    // a resize event for itself immediately after calling this function (in
+    // order to shrink the window to fit the new display size if necessary). If
+    // we don't queue a resize here, the window will become tiny because we 
will
+    // only request 50x50 during the window resize
+    virt_viewer_display_queue_resize(display);
+
     if (priv->zoom_level == zoom)
         return;
 
     priv->zoom_level = zoom;
 
-    virt_viewer_display_queue_resize(display);
     g_object_notify(G_OBJECT(display), "zoom-level");
 }
 
++++++ 53a8716d-fix-un-shrinkable-displays-on-windows-guests.patch ++++++
Subject: rhbz#1111514: Fix un-shrinkable displays on windows guests
From: Jonathon Jongsma [email protected] Fri Jun 20 14:39:12 2014 -0500
Date: Mon Jun 23 13:26:53 2014 -0500:
Git: eaaa4f5106a9707e4b9a9cd7b52accde3459333d

Commit 6edde5786 introduced a regression wrt shrinking windows on windows
guests. This seems to be because resizing a display often causes the notebook
widget to switch to the status page temporarily (often so quickly that it's not
noticeable to the eye). This causes a quick 'unmap' and 'map' event sequence on
the display widget. Apparently the timing of these events varies enough between
linux and windows guests that it is only noticeable on windows gueststhe timing
of these events varies enough between linux and windows guests that it is only
noticeable on windows guests. The exact sequence that causes the bug appears to
be as follows:

1 user resizes window smaller
2 display widget gets a new allocation, which causes it to send a display
  reconfiguration to the guest
3 client receives a new show-hint for the display which causes it to switch
  temporarily to the 'status' notebook page
4 display widget gets unmapped
5 Client receives another new show-hint, which causes the display widget to get
  re- mapped, which causes client to send a display reconfiguration to the guest
  (using the old size)
6 client receives new (smaller, from step 2) display size and temporarily
  changes to the new size
7 client receives new (larger, from step 5) display size and changes back to
  original size.

To fix the issue, we only explicitly request a resize in response to the very
first map event, and for any subsequent map events, we simply call
_make_resizable() as before.

Index: virt-viewer-0.6.0/src/virt-viewer-display.c
===================================================================
--- virt-viewer-0.6.0.orig/src/virt-viewer-display.c
+++ virt-viewer-0.6.0/src/virt-viewer-display.c
@@ -38,6 +38,7 @@ struct _VirtViewerDisplayPrivate
 {
 #if !GTK_CHECK_VERSION(3, 0, 0)
     gboolean dirty;
+    gboolean mapped_once;
 #endif
     guint desktopWidth;
     guint desktopHeight;
@@ -439,9 +440,16 @@ virt_viewer_display_make_resizable(VirtV
 static void
 virt_viewer_display_map(GtkWidget *widget)
 {
+    VirtViewerDisplay* self = VIRT_VIEWER_DISPLAY(widget);
+
     GTK_WIDGET_CLASS(virt_viewer_display_parent_class)->map(widget);
 
-    virt_viewer_display_queue_resize(VIRT_VIEWER_DISPLAY(widget));
+    if (!self->priv->mapped_once)
+        virt_viewer_display_queue_resize(self);
+    else
+        virt_viewer_display_make_resizable(self);
+
+    self->priv->mapped_once = TRUE;
 }
 
 #else
++++++ netware-keycombo.patch ++++++
--- /var/tmp/diff_new_pack.1Y8X2Y/_old  2014-07-02 15:05:37.000000000 +0200
+++ /var/tmp/diff_new_pack.1Y8X2Y/_new  2014-07-02 15:05:37.000000000 +0200
@@ -2,7 +2,7 @@
 ===================================================================
 --- virt-viewer-0.6.0.orig/src/virt-viewer-window.c
 +++ virt-viewer-0.6.0/src/virt-viewer-window.c
-@@ -579,6 +579,15 @@ static const struct keyComboDef keyCombo
+@@ -584,6 +584,15 @@ static const struct keyComboDef keyCombo
      { { GDK_Control_L, GDK_Alt_L, GDK_BackSpace, GDK_VoidSymbol }, 
N_("Ctrl+Alt+_Backspace"), NULL},
      { { GDK_Control_R, GDK_Scroll_Lock, GDK_Scroll_Lock, GDK_VoidSymbol }, 
N_("Ctrl+Scroll+Scroll"), NULL},
      { { GDK_VoidSymbol }, "" , NULL},
@@ -18,7 +18,7 @@
      { { GDK_Control_L, GDK_Alt_L, GDK_F1, GDK_VoidSymbol }, 
N_("Ctrl+Alt+F_1"), NULL},
      { { GDK_Control_L, GDK_Alt_L, GDK_F2, GDK_VoidSymbol }, 
N_("Ctrl+Alt+F_2"), NULL},
      { { GDK_Control_L, GDK_Alt_L, GDK_F3, GDK_VoidSymbol }, 
N_("Ctrl+Alt+F_3"), NULL},
-@@ -588,7 +597,7 @@ static const struct keyComboDef keyCombo
+@@ -593,7 +602,7 @@ static const struct keyComboDef keyCombo
      { { GDK_Control_L, GDK_Alt_L, GDK_F7, GDK_VoidSymbol }, 
N_("Ctrl+Alt+F_7"), NULL},
      { { GDK_Control_L, GDK_Alt_L, GDK_F8, GDK_VoidSymbol }, 
N_("Ctrl+Alt+F_8"), NULL},
      { { GDK_Control_L, GDK_Alt_L, GDK_F9, GDK_VoidSymbol }, 
N_("Ctrl+Alt+F_9"), NULL},
@@ -27,3 +27,25 @@
      { { GDK_Control_L, GDK_Alt_L, GDK_F11, GDK_VoidSymbol }, 
N_("Ctrl+Alt+F11"), NULL},
      { { GDK_Control_L, GDK_Alt_L, GDK_F12, GDK_VoidSymbol }, 
N_("Ctrl+Alt+F12"), NULL},
      { { GDK_VoidSymbol }, "" , NULL},
+Index: virt-viewer-0.6.0/src/virt-gtk-compat.h
+===================================================================
+--- virt-viewer-0.6.0.orig/src/virt-gtk-compat.h
++++ virt-viewer-0.6.0/src/virt-gtk-compat.h
+@@ -35,13 +35,17 @@ G_BEGIN_DECLS
+ 
+ #if GTK_CHECK_VERSION(3, 0, 0)
+ #define GDK_Shift_L GDK_KEY_Shift_L
++#define GDK_Shift_R GDK_KEY_Shift_R
+ #define GDK_VoidSymbol GDK_KEY_VoidSymbol
+ #define GDK_Control_L GDK_KEY_Control_L
+ #define GDK_Control_R GDK_KEY_Control_R
+ #define GDK_Scroll_Lock GDK_KEY_Scroll_Lock
+ #define GDK_Alt_L GDK_KEY_Alt_L
++#define GDK_Alt_R GDK_KEY_Alt_R
+ #define GDK_Delete GDK_KEY_Delete
+ #define GDK_End GDK_KEY_End
++#define GDK_Escape GDK_KEY_Escape
++#define GDK_Tab GDK_KEY_Tab
+ #define GDK_BackSpace GDK_KEY_BackSpace
+ #define GDK_Print GDK_KEY_Print
+ #define GDK_F1 GDK_KEY_F1

++++++ windows-keycombo.patch ++++++
--- /var/tmp/diff_new_pack.1Y8X2Y/_old  2014-07-02 15:05:37.000000000 +0200
+++ /var/tmp/diff_new_pack.1Y8X2Y/_new  2014-07-02 15:05:37.000000000 +0200
@@ -2,7 +2,7 @@
 ===================================================================
 --- virt-viewer-0.6.0.orig/src/virt-viewer-window.c
 +++ virt-viewer-0.6.0/src/virt-viewer-window.c
-@@ -577,6 +577,7 @@ struct keyComboDef {
+@@ -582,6 +582,7 @@ struct keyComboDef {
  static const struct keyComboDef keyCombos[] = {
      { { GDK_Control_L, GDK_Alt_L, GDK_Delete, GDK_VoidSymbol }, 
N_("Ctrl+Alt+_Del"), "<virt-viewer>/send/secure-attention"},
      { { GDK_Control_L, GDK_Alt_L, GDK_BackSpace, GDK_VoidSymbol }, 
N_("Ctrl+Alt+_Backspace"), NULL},
@@ -10,3 +10,16 @@
      { { GDK_VoidSymbol }, "" , NULL},
      { { GDK_Control_L, GDK_Alt_L, GDK_F1, GDK_VoidSymbol }, 
N_("Ctrl+Alt+F_1"), NULL},
      { { GDK_Control_L, GDK_Alt_L, GDK_F2, GDK_VoidSymbol }, 
N_("Ctrl+Alt+F_2"), NULL},
+Index: virt-viewer-0.6.0/src/virt-gtk-compat.h
+===================================================================
+--- virt-viewer-0.6.0.orig/src/virt-gtk-compat.h
++++ virt-viewer-0.6.0/src/virt-gtk-compat.h
+@@ -37,6 +37,8 @@ G_BEGIN_DECLS
+ #define GDK_Shift_L GDK_KEY_Shift_L
+ #define GDK_VoidSymbol GDK_KEY_VoidSymbol
+ #define GDK_Control_L GDK_KEY_Control_L
++#define GDK_Control_R GDK_KEY_Control_R
++#define GDK_Scroll_Lock GDK_KEY_Scroll_Lock
+ #define GDK_Alt_L GDK_KEY_Alt_L
+ #define GDK_Delete GDK_KEY_Delete
+ #define GDK_End GDK_KEY_End

-- 
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to