[virt-tools-list] [PATCH virt-viewer 07/12] kiosk: teach a window to become kiosk-mode
Daniel P. Berrange
berrange at redhat.com
Fri Aug 16 11:16:32 UTC 2013
On Fri, Aug 16, 2013 at 01:05:45PM +0200, Marc-André Lureau wrote:
> On Thu, Aug 15, 2013 at 4:43 PM, Daniel P. Berrange <berrange at redhat.com> wrote:
> > On Mon, Jul 15, 2013 at 09:36:14PM +0200, Marc-André Lureau wrote:
> >> Remove the toolbar, disable modifiers.
> >> ---
> >> src/virt-viewer-window.c | 20 ++++++++++++++++++++
> >> 1 file changed, 20 insertions(+)
> >>
> >> diff --git a/src/virt-viewer-window.c b/src/virt-viewer-window.c
> >> index 69e50b8..f483027 100644
> >> --- a/src/virt-viewer-window.c
> >> +++ b/src/virt-viewer-window.c
> >> @@ -1155,6 +1155,23 @@ virt_viewer_window_set_display(VirtViewerWindow *self, VirtViewerDisplay *displa
> >> }
> >> }
> >>
> >> +static void
> >> +virt_viewer_window_enable_kiosk(VirtViewerWindow *self)
> >> +{
> >> + VirtViewerWindowPrivate *priv;
> >> +
> >> + g_return_if_fail(VIRT_VIEWER_IS_WINDOW(self));
> >> + priv = self->priv;
> >> +
> >> + ViewOvBox_SetOver(VIEW_OV_BOX(priv->layout), gtk_drawing_area_new());
> >> + ViewAutoDrawer_SetActive(VIEW_AUTODRAWER(priv->layout), FALSE);
> >> + ViewAutoDrawer_SetOverlapPixels(VIEW_AUTODRAWER(priv->layout), 0);
> >
> > IIUC, here you are replacing the widget previously setup as the "over"
> > window. Can we just not add the toolbar in the first place, rather
> > than removing it afterwards.
>
> I had in mind that you can enable kiosk mode dynamically (ie start
> normally, and turn it on later). So, I'd keep that way.
Ok, that's reasonable
> >
> >> +
> >> + // You probably also want X11 Option "DontVTSwitch" "true"
> >> + // and perhaps more distro/desktop-specific options
> >
> > C style comments please
> >
>
> ok
Daniel
--
|: http://berrange.com -o- http://www.flickr.com/photos/dberrange/ :|
|: http://libvirt.org -o- http://virt-manager.org :|
|: http://autobuild.org -o- http://search.cpan.org/~danberr/ :|
|: http://entangle-photo.org -o- http://live.gnome.org/gtk-vnc :|
More information about the virt-tools-list
mailing list