[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]

Re: [virt-tools-list] [PATCH 4 of 5] viewer: Add support for Spice



On Tue, Nov 30, 2010 at 04:08:32PM +0100, Marc-André Lureau wrote:
> # HG changeset patch
> # User Marc-André Lureau <marcandre lureau redhat com>
> # Date 1291121941 -3600
> # Node ID 4ac66a955d7bf718ce85e8ffd0be00f0c4ad8ac6
> # Parent  9f8a6e933516586fc82982cffb4721f5539c9d2f
> viewer: Add support for Spice
> 
> diff -r 9f8a6e933516 -r 4ac66a955d7b AUTHORS
> --- a/AUTHORS	Fri Nov 19 18:09:42 2010 +0100
> +++ b/AUTHORS	Tue Nov 30 13:59:01 2010 +0100
> @@ -13,6 +13,7 @@
>      Guido G\374nther <agx-at-sigxcpu-dot-org>
>      Hiroyuki Kaguchi <fj7025cf-at-aa-dot-jp-dot-fujitsu-dot-com>
>      Ronnie Sahlberg <ronniesahlberg gmail com>
> +    Marc-André Lureau <marcandre.lureau-at-redhat-dot-com>
>  
>     ...send patches to get your name here...
>  
> diff -r 9f8a6e933516 -r 4ac66a955d7b configure.ac
> --- a/configure.ac	Fri Nov 19 18:09:42 2010 +0100
> +++ b/configure.ac	Tue Nov 30 13:59:01 2010 +0100
> @@ -33,6 +33,7 @@
>  PKG_CHECK_MODULES(GTK2, gtk+-2.0 >= 2.10.0)
>  PKG_CHECK_MODULES(LIBGLADE2, libglade-2.0 >= 2.6.0)
>  PKG_CHECK_MODULES(GTKVNC, gtk-vnc-1.0 >= 0.3.8)
> +PKG_CHECK_MODULES(SPICEGTK, spice-client-gtk >= 0.1.0.14)
>  
>  dnl Decide if this platform can support the SSH tunnel feature.
>  AC_CHECK_HEADERS([sys/socket.h sys/un.h windows.h])

Since it depends on an external library that is not yet
widely deployed across Linux distros, I think it would be
desirable to let the SPICE support be conditionally
compiled based on whether it is found in configure.

> diff -r 9f8a6e933516 -r 4ac66a955d7b src/viewer-priv.h
> --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
> +++ b/src/viewer-priv.h	Tue Nov 30 13:59:01 2010 +0100
> +#ifndef _VIRT_VIEWER_PRIV_H
> +# define _VIRT_VIEWER_PRIV_H


> +struct _VirtViewer {
> +	char *uri;
> +	virConnectPtr conn;
> +	char *domkey;
> +	char *domtitle;
> +
> +	GladeXML *glade;
> +	GtkWidget *window;
> +	GtkWidget *container;
> +
> +	char *pretty_address;
> +
> +	int zoomlevel;
> +
> +	int desktopWidth;
> +	int desktopHeight;
> +	gboolean autoResize;
> +	gboolean fullscreen;
> +	gboolean withEvents;
> +
> +	gboolean active;
> +
> +	gboolean accelEnabled;
> +	GValue accelSetting;
> +	GSList *accelList;
> +	int accelMenuSig[LAST_MENU];
> +
> +	gboolean waitvm;
> +	gboolean reconnect;
> +	gboolean direct;
> +	gboolean verbose;
> +	gboolean authretry;
> +	gboolean connected;
> +
> +	gchar *clipboard;
> +
> +	VirtViewerDisplay *display;
> +
> +	char *gport;
> +	char *host;
> +	char *transport;
> +	char *user;
> +        int port;
> +};

I've not looked closely at the code, but if it is practical,
it'd be preferrable to keep this struct private in the
viewer.c file

Daniel


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]