[virt-tools-list] [PATCH virt-viewer] Support Spice controller "auto-display-res" flag

Christophe Fergeau cfergeau at redhat.com
Mon May 27 13:17:20 UTC 2013


On Mon, May 27, 2013 at 02:25:51PM +0200, Marc-André Lureau wrote:
> The controller "auto-display-res" flag should be use to reconfigure
> guest to match client configuration. This is what the
> --fullscreen=auto-conf option is already made for.
> 
> https://bugzilla.redhat.com/show_bug.cgi?id=967154
> ---
>  src/remote-viewer.c | 5 ++---
>  1 file changed, 2 insertions(+), 3 deletions(-)
> 
> diff --git a/src/remote-viewer.c b/src/remote-viewer.c
> index a0adef7..20724f6 100644
> --- a/src/remote-viewer.c
> +++ b/src/remote-viewer.c
> @@ -549,9 +549,8 @@ spice_ctrl_notified(SpiceCtrlController *ctrl,
>          guint flags = g_value_get_uint(&value);
>          gboolean fullscreen = flags & CONTROLLER_SET_FULL_SCREEN;
>          gboolean auto_res = flags & CONTROLLER_AUTO_DISPLAY_RES;
> -        g_object_set(G_OBJECT(self), "fullscreen", fullscreen, NULL);
> -        g_debug("unimplemented resize-guest %d", auto_res);
> -        /* g_object_set(G_OBJECT(self), "resize-guest", auto_res, NULL); */
> +        g_object_set(G_OBJECT(self), "fullscreen", !!fullscreen, NULL);
> +        g_object_set(G_OBJECT(self), "fullscreen-auto-conf", !!auto_res, NULL);

nit: I'd move the !! to fullscreen/auto_res initialization:

gboolean fullscreen = !!(flags & CONTROLLER_SET_FULL_SCREEN);

Looks good otherwise, a bit surprised this was missing all along, ACK.

Christophe
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 198 bytes
Desc: not available
URL: <http://listman.redhat.com/archives/virt-tools-list/attachments/20130527/14b2c966/attachment.sig>


More information about the virt-tools-list mailing list