fs->hide_mouse_id = g_timeout_add(FULL_SCREEN_HIDE_MOUSE_DELAY, fullscreen_hide_mouse_cb, fs);
}
-static gboolean fullscreen_mouse_moved(GtkWidget *widget, GdkEventButton *bevent, gpointer data)
+static gboolean fullscreen_mouse_moved(GtkWidget *widget, GdkEventMotion *event, gpointer data)
{
FullScreenData *fs = data;
gtk_window_set_decorated(GTK_WINDOW(fs->window), FALSE);
gtk_container_set_border_width(GTK_CONTAINER(fs->window), 0);
- /* make window fullscreen -- let Gtk do it's job, don't screw it in any way */
- gtk_window_fullscreen(GTK_WINDOW(fs->window));
-
- /* move it to requested screen */
- if (options->fullscreen.screen >= 0) {
- gtk_window_set_screen(GTK_WINDOW(fs->window), screen);
- }
-
/* keep window above others, if requested */
if (options->fullscreen.above) {
gtk_window_set_keep_above(GTK_WINDOW(fs->window), TRUE);
GDK_HINT_WIN_GRAVITY | GDK_HINT_USER_POS | GDK_HINT_USER_SIZE);
gtk_widget_realize(fs->window);
+#if GTK_CHECK_VERSION(3,8,0)
+ if ((options->fullscreen.screen % 100) == 0)
+ {
+ GdkWindow *gdkwin;
+ gdkwin = gtk_widget_get_window(fs->window);
+ if (gdkwin != NULL)
+ gdk_window_set_fullscreen_mode(gdkwin, GDK_FULLSCREEN_ON_ALL_MONITORS);
+ }
+#endif
+ /* make window fullscreen -- let Gtk do it's job, don't screw it in any way */
+ gtk_window_fullscreen(GTK_WINDOW(fs->window));
+
+ /* move it to requested screen */
+ if (options->fullscreen.screen >= 0)
+ {
+ gtk_window_set_screen(GTK_WINDOW(fs->window), screen);
+ }
fs->imd = image_new(FALSE);
if (fs->same_region)
{
- DEBUG_0("Original window is not visible, enabling std. fullscreen mode");
+ DEBUG_2("Original window is not visible, enabling std. fullscreen mode");
image_move_from_image(fs->imd, fs->normal_imd);
}
else
{
- DEBUG_0("Original window is still visible, enabling presentation fullscreen mode");
+ DEBUG_2("Original window is still visible, enabling presentation fullscreen mode");
image_copy_from_image(fs->imd, fs->normal_imd);
}
gtk_widget_destroy(fs->window);
+ gtk_window_present(GTK_WINDOW(fs->normal_window));
+
g_free(fs);
}