diff options
-rw-r--r-- | ChangeLog | 12 | ||||
-rw-r--r-- | NEWS | 4 | ||||
-rw-r--r-- | README | 2 | ||||
-rw-r--r-- | src/backend/bacon-video-widget-xine.c | 10 | ||||
-rw-r--r-- | src/bacon-video-widget-xine.c | 10 | ||||
-rw-r--r-- | src/totem.c | 38 |
6 files changed, 55 insertions, 21 deletions
@@ -1,3 +1,15 @@ +2004-06-08 Bastien Nocera <hadess@hadess.net> + + * README: upd + * src/bacon-video-widget-xine.c: (xine_event_message), + (xine_error): fix a problem where filenames containing escape codes + (for example file:///foo%20bar) could cause the reason of an error + not to appear in the dialog + * src/totem.c: (totem_action_error), (action_toggle_playlist), + (totem_action_set_mrl), (on_show_playlist1_activate), + (totem_action_handle_key), (on_window_key_press_event): + Handle Ctrl+P for the playlist even in hidden controls mode + ============ Version 0.99.12 2004-06-04 Bastien Nocera <hadess@hadess.net> @@ -1,5 +1,9 @@ New features and significant updates in version... +????: +* Fix cases where the reason for not being able to open a file could be missing +* Handle Ctrl+P to show the playlist even in hidden controls mode + 0.99.12: * Starts of a Mozilla plugin * Fixes for Right-to-Left languages @@ -17,7 +17,7 @@ See NEWS file Dependencies ============ -xine-lib 1.0 rc3c or newer: +xine-lib 1.0 rc4a or newer: http://xinehq.de GNOME 2.2 development platform: http://www.gnome.org diff --git a/src/backend/bacon-video-widget-xine.c b/src/backend/bacon-video-widget-xine.c index e908fe906..f039a4124 100644 --- a/src/backend/bacon-video-widget-xine.c +++ b/src/backend/bacon-video-widget-xine.c @@ -1284,7 +1284,7 @@ xine_event_message (BaconVideoWidget *bvw, xine_ui_message_data_t *data) case XINE_MSG_GENERAL_WARNING: break; case XINE_MSG_UNKNOWN_HOST: - message = g_strdup_printf (_("The server you are trying to connect to is not known.")); + message = g_strdup (_("The server you are trying to connect to is not known.")); break; case XINE_MSG_UNKNOWN_DEVICE: message = g_strdup_printf (_("The device name you specified (%s) seems to be invalid."), (char *) data + data->parameters); @@ -1293,13 +1293,13 @@ xine_event_message (BaconVideoWidget *bvw, xine_ui_message_data_t *data) message = g_strdup_printf (_("The server you are trying to connect to (%s) is unreachable."), (char *) data + data->parameters); break; case XINE_MSG_CONNECTION_REFUSED: - message = g_strdup_printf (_("The connection to this server was refused.")); + message = g_strdup (_("The connection to this server was refused.")); break; case XINE_MSG_FILE_NOT_FOUND: - message = g_strdup_printf (_("The specified movie '%s' could not be found."), (char *) data + data->parameters); + message = g_strdup (_("The specified movie could not be found.")); break; case XINE_MSG_READ_ERROR: - message = g_strdup_printf (_("The movie '%s' could not be read."), (char *) data + data->parameters); + message = g_strdup (_("The movie could not be read.")); break; case XINE_MSG_LIBRARY_LOAD_ERROR: message = g_strdup_printf (_("A problem occured while loading a library or a decoder (%s)."), (char *) data + data->parameters); @@ -1432,7 +1432,7 @@ xine_error (BaconVideoWidget *bvw, GError **error) if (save_data != NULL) { - g_set_error (error, 0, 0, save_data->msg); + g_set_error (error, 0, 0, "%s", save_data->msg); g_free (save_data->msg); g_free (save_data); diff --git a/src/bacon-video-widget-xine.c b/src/bacon-video-widget-xine.c index e908fe906..f039a4124 100644 --- a/src/bacon-video-widget-xine.c +++ b/src/bacon-video-widget-xine.c @@ -1284,7 +1284,7 @@ xine_event_message (BaconVideoWidget *bvw, xine_ui_message_data_t *data) case XINE_MSG_GENERAL_WARNING: break; case XINE_MSG_UNKNOWN_HOST: - message = g_strdup_printf (_("The server you are trying to connect to is not known.")); + message = g_strdup (_("The server you are trying to connect to is not known.")); break; case XINE_MSG_UNKNOWN_DEVICE: message = g_strdup_printf (_("The device name you specified (%s) seems to be invalid."), (char *) data + data->parameters); @@ -1293,13 +1293,13 @@ xine_event_message (BaconVideoWidget *bvw, xine_ui_message_data_t *data) message = g_strdup_printf (_("The server you are trying to connect to (%s) is unreachable."), (char *) data + data->parameters); break; case XINE_MSG_CONNECTION_REFUSED: - message = g_strdup_printf (_("The connection to this server was refused.")); + message = g_strdup (_("The connection to this server was refused.")); break; case XINE_MSG_FILE_NOT_FOUND: - message = g_strdup_printf (_("The specified movie '%s' could not be found."), (char *) data + data->parameters); + message = g_strdup (_("The specified movie could not be found.")); break; case XINE_MSG_READ_ERROR: - message = g_strdup_printf (_("The movie '%s' could not be read."), (char *) data + data->parameters); + message = g_strdup (_("The movie could not be read.")); break; case XINE_MSG_LIBRARY_LOAD_ERROR: message = g_strdup_printf (_("A problem occured while loading a library or a decoder (%s)."), (char *) data + data->parameters); @@ -1432,7 +1432,7 @@ xine_error (BaconVideoWidget *bvw, GError **error) if (save_data != NULL) { - g_set_error (error, 0, 0, save_data->msg); + g_set_error (error, 0, 0, "%s", save_data->msg); g_free (save_data->msg); g_free (save_data); diff --git a/src/totem.c b/src/totem.c index 0696c91c5..58c58eefb 100644 --- a/src/totem.c +++ b/src/totem.c @@ -167,6 +167,9 @@ totem_action_error (char *title, char *reason, Totem *totem) GtkWidget *parent, *error_dialog; char *title_esc, *reason_esc; + if (reason == NULL) + g_warning ("totem_action_error called with reason == NULL"); + if (totem == NULL) parent = NULL; else @@ -276,6 +279,18 @@ totem_action_exit (Totem *totem) exit (0); } +static void +action_toggle_playlist (Totem *totem) +{ + GtkWidget *toggle; + gboolean state; + + toggle = glade_xml_get_widget (totem->xml, "tmw_playlist_button"); + + state = gtk_toggle_button_get_active (GTK_TOGGLE_BUTTON (toggle)); + gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (toggle), !state); +} + static gboolean main_window_destroy_cb (GtkWidget *widget, GdkEvent *event, Totem *totem) { @@ -816,10 +831,9 @@ totem_action_set_mrl (Totem *totem, const char *mrl) msg = g_strdup_printf(_("Totem could not play '%s'."), disp); g_free (disp); totem_action_error (msg, err->message, totem); - g_free (msg); + g_free (msg); g_error_free (err); - retval = FALSE; } } update_buttons (totem); @@ -1760,13 +1774,7 @@ on_aspect_ratio_dvb_activate (GtkButton *button, Totem *totem) static void on_show_playlist1_activate (GtkButton *button, Totem *totem) { - GtkWidget *toggle; - gboolean state; - - toggle = glade_xml_get_widget (totem->xml, "tmw_playlist_button"); - - state = gtk_toggle_button_get_active (GTK_TOGGLE_BUTTON (toggle)); - gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (toggle), !state); + action_toggle_playlist (totem); } static void @@ -2606,7 +2614,11 @@ totem_action_handle_key (Totem *totem, GdkEventKey *event) #endif /* HAVE_XFREE */ case GDK_p: case GDK_P: - totem_action_play_pause (totem); + /* Playlist keyboard shortcut? */ + if (event->state & GDK_CONTROL_MASK) + action_toggle_playlist (totem); + else + totem_action_play_pause (totem); break; case GDK_q: case GDK_Q: @@ -2713,6 +2725,12 @@ totem_action_handle_volume_scroll (Totem *totem, GdkScrollDirection direction) static int on_window_key_press_event (GtkWidget *win, GdkEventKey *event, Totem *totem) { + /* Special case the Playlist keyboard shortcut */ + if (event->state != 0 + && (event->state &GDK_CONTROL_MASK) + && ((event->keyval == GDK_p) || event->keyval == GDK_P)) + return totem_action_handle_key (totem, event); + /* If we have modifiers, and either Ctrl, Mod1 (Alt), or any * of Mod3 to Mod5 (Mod2 is num-lock...) are pressed, we * let Gtk+ handle the key */ |