Ejemplo n.º 1
0
/* this is used to grab the keyboard and mouse to an offscreen window */
gboolean
gs_grab_grab_offscreen (GSGrab *grab,
                        gboolean hide_cursor)
{
        GdkScreen *screen;
        gboolean   res;

        gs_debug ("Grabbing an offscreen window");

        screen = gtk_invisible_get_screen (GTK_INVISIBLE (grab->priv->invisible));
        res = gs_grab_grab_window (grab, gtk_widget_get_window (grab->priv->invisible), screen, hide_cursor);

        return res;
}
Ejemplo n.º 2
0
int
clip_GTK_INVISIBLESETSCREEN(ClipMachine * ClipMachineMemory)
{
   C_widget *cinvis = _fetch_cw_arg(ClipMachineMemory);

   C_object *cscreen = _fetch_cobject(ClipMachineMemory, _clip_spar(ClipMachineMemory, 2));

   CHECKCWID(cinvis, GTK_IS_INVISIBLE);
   CHECKCOBJ(cscreen, GDK_IS_SCREEN(cscreen->object));

   gtk_invisible_set_screen(GTK_INVISIBLE(cinvis->widget), GDK_SCREEN(cscreen->object));

   return 0;
 err:
   return 1;
}
Ejemplo n.º 3
0
/* this is used to grab the keyboard and mouse to an offscreen window */
gboolean
gs_grab_grab_offscreen (GSGrab *grab,
                        gboolean hide_cursor)
{
	GdkScreen *screen;
	gboolean   res;

	gs_debug ("Grabbing an offscreen window");

	screen = gtk_invisible_get_screen (GTK_INVISIBLE (grab->priv->invisible));
#if GTK_CHECK_VERSION (3, 0, 0)
	res = gs_grab_grab_window (grab, gtk_widget_get_window (GTK_WIDGET (grab->priv->invisible)), screen, hide_cursor);
#else
	res = gs_grab_grab_window (grab, grab->priv->invisible->window, screen, hide_cursor);
#endif

	return res;
}
Ejemplo n.º 4
0
int
clip_GTK_INVISIBLEGETSCREEN(ClipMachine * ClipMachineMemory)
{
   C_widget *cinvis = _fetch_cw_arg(ClipMachineMemory);

   GdkScreen *screen;

   C_object *cscreen;

   CHECKCWID(cinvis, GTK_IS_INVISIBLE);

   screen = gtk_invisible_get_screen(GTK_INVISIBLE(cinvis->widget));
   if (screen)
    {
       cscreen = _list_get_cobject(ClipMachineMemory, screen);
       if (!cscreen)
	  cscreen = _register_object(ClipMachineMemory, screen, GDK_TYPE_SCREEN, NULL, NULL);
       if (cscreen)
	  _clip_mclone(ClipMachineMemory, RETPTR(ClipMachineMemory), &cscreen->obj);
    }
   return 0;
 err:
   return 1;
}