totem r5835 - in trunk: . src
- From: hadess svn gnome org
- To: svn-commits-list gnome org
- Subject: totem r5835 - in trunk: . src
- Date: Mon, 8 Dec 2008 11:40:59 +0000 (UTC)
Author: hadess
Date: Mon Dec 8 11:40:59 2008
New Revision: 5835
URL: http://svn.gnome.org/viewvc/totem?rev=5835&view=rev
Log:
2008-12-08 Bastien Nocera <hadess hadess net>
* src/totem-fullscreen.c (totem_fullscreen_motion_notify),
(totem_fullscreen_show_popups):
* src/totem-fullscreen.h:
* src/totem.c (totem_action_remote), (on_mouse_click_fullscreen),
(totem_action_handle_key_press), (totem_action_handle_scroll):
Show the popup when seeking with the keyboard in fullscreen,
patch from Robin Stocker <robin nibor org> (Closes: #559024)
Modified:
trunk/ChangeLog
trunk/src/totem-fullscreen.c
trunk/src/totem-fullscreen.h
trunk/src/totem.c
Modified: trunk/src/totem-fullscreen.c
==============================================================================
--- trunk/src/totem-fullscreen.c (original)
+++ trunk/src/totem-fullscreen.c Mon Dec 8 11:40:59 2008
@@ -256,15 +256,22 @@
totem_fullscreen_motion_notify (GtkWidget *widget, GdkEventMotion *event,
TotemFullscreen *fs)
{
+ totem_fullscreen_show_popups (fs, TRUE);
+ return FALSE;
+}
+
+void
+totem_fullscreen_show_popups (TotemFullscreen *fs, gboolean show_cursor)
+{
GtkWidget *item;
g_assert (fs->is_fullscreen != FALSE);
if (fs->priv->popup_in_progress != FALSE)
- return FALSE;
+ return;
if (gtk_window_is_active (GTK_WINDOW (fs->priv->parent_window)) == FALSE)
- return FALSE;
+ return;
fs->priv->popup_in_progress = TRUE;
@@ -281,15 +288,15 @@
gtk_widget_show_all (fs->priv->exit_popup);
gtk_widget_show_all (fs->priv->control_popup);
- /* Show the mouse cursor */
- totem_fullscreen_set_cursor (fs, TRUE);
+ if (show_cursor != FALSE) {
+ /* Show the mouse cursor */
+ totem_fullscreen_set_cursor (fs, TRUE);
+ }
/* Reset the popup timeout */
totem_fullscreen_popup_timeout_add (fs);
fs->priv->popup_in_progress = FALSE;
-
- return FALSE;
}
void
Modified: trunk/src/totem-fullscreen.h
==============================================================================
--- trunk/src/totem-fullscreen.h (original)
+++ trunk/src/totem-fullscreen.h Mon Dec 8 11:40:59 2008
@@ -72,9 +72,8 @@
BaconVideoWidget *bvw);
void totem_fullscreen_set_parent_window (TotemFullscreen *fs,
GtkWindow *parent_window);
-gboolean totem_fullscreen_motion_notify (GtkWidget *widget,
- GdkEventMotion *event,
- TotemFullscreen *fs);
+void totem_fullscreen_show_popups (TotemFullscreen *fs,
+ gboolean show_cursor);
gboolean totem_fullscreen_is_fullscreen (TotemFullscreen *fs);
void totem_fullscreen_set_fullscreen (TotemFullscreen *fs,
gboolean fullscreen);
Modified: trunk/src/totem.c
==============================================================================
--- trunk/src/totem.c (original)
+++ trunk/src/totem.c Mon Dec 8 11:40:59 2008
@@ -2396,7 +2396,7 @@
if (handled != FALSE
&& gtk_window_is_active (GTK_WINDOW (totem->win))
&& totem_fullscreen_is_fullscreen (totem->fs) != FALSE) {
- totem_fullscreen_motion_notify (NULL, NULL, totem->fs);
+ totem_fullscreen_show_popups (totem->fs, TRUE);
}
}
@@ -2602,7 +2602,7 @@
on_mouse_click_fullscreen (GtkWidget *widget, Totem *totem)
{
if (totem_fullscreen_is_fullscreen (totem->fs) != FALSE)
- totem_fullscreen_motion_notify (NULL, NULL, totem->fs);
+ totem_fullscreen_show_popups (totem->fs, TRUE);
}
static gboolean
@@ -2829,16 +2829,19 @@
totem_action_fullscreen (totem, FALSE);
break;
case GDK_Left:
- if (gtk_widget_get_direction (totem->win) == GTK_TEXT_DIR_RTL)
- totem_action_handle_seek (totem, event, TRUE);
- else
- totem_action_handle_seek (totem, event, FALSE);
- break;
case GDK_Right:
- if (gtk_widget_get_direction (totem->win) == GTK_TEXT_DIR_RTL)
- totem_action_handle_seek (totem, event, FALSE);
- else
- totem_action_handle_seek (totem, event, TRUE);
+ {
+ gboolean is_forward;
+
+ if (totem_is_fullscreen (totem) != FALSE)
+ totem_fullscreen_show_popups (totem->fs, FALSE);
+
+ is_forward = (event->keyval == GDK_Right);
+ /* Switch direction in RTL environment */
+ if (gtk_widget_get_direction (totem->win) == GTK_TEXT_DIR_RTL)
+ is_forward = !is_forward;
+ totem_action_handle_seek (totem, event, is_forward);
+ }
break;
case GDK_space:
if (totem_is_fullscreen (totem) != FALSE || gtk_widget_is_focus (GTK_WIDGET (totem->bvw)) != FALSE)
@@ -2929,7 +2932,7 @@
gboolean retval = TRUE;
if (totem_fullscreen_is_fullscreen (totem->fs) != FALSE)
- totem_fullscreen_motion_notify (NULL, NULL, totem->fs);
+ totem_fullscreen_show_popups (totem->fs, TRUE);
switch (direction) {
case GDK_SCROLL_UP:
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]