[rhythmbox/media-player-sync] media-player: always update the sync state when sync action is invoked
- From: Jonathan Matthew <jmatthew src gnome org>
- To: svn-commits-list gnome org
- Cc:
- Subject: [rhythmbox/media-player-sync] media-player: always update the sync state when sync action is invoked
- Date: Mon, 1 Feb 2010 13:04:34 +0000 (UTC)
commit a900afad35bbe7fca303a55bcd3e7ccffe02b7d4
Author: Jonathan Matthew <jonathan d14n org>
Date: Mon Feb 1 23:02:10 2010 +1000
media-player: always update the sync state when sync action is invoked
The only thing that can happen if we decide not to update the sync state
is that we use outdated sync state data, or we don't have any sync state
data so we don't sync anything.
sources/rb-media-player-source.c | 7 +------
1 files changed, 1 insertions(+), 6 deletions(-)
---
diff --git a/sources/rb-media-player-source.c b/sources/rb-media-player-source.c
index 6ae1045..36addf0 100644
--- a/sources/rb-media-player-source.c
+++ b/sources/rb-media-player-source.c
@@ -57,7 +57,6 @@ typedef struct {
GtkWidget *preview_bar;
/* sync state */
- gboolean sync_needs_update;
guint64 sync_space_needed;
GList *sync_to_add;
GList *sync_to_remove;
@@ -1005,7 +1004,6 @@ update_sync (RBMediaPlayerSource *source)
g_hash_table_destroy (itinerary);
update_sync_space_needed (source);
- priv->sync_needs_update = FALSE;
}
static void
@@ -1101,7 +1099,6 @@ sync_idle_cb_cleanup (RBMediaPlayerSource *source)
RBMediaPlayerSourcePrivate *priv = MEDIA_PLAYER_SOURCE_GET_PRIVATE (source);
rb_debug ("cleaning up after sync process");
- priv->sync_needs_update = TRUE;
gtk_action_set_sensitive (priv->sync_action, TRUE);
@@ -1174,9 +1171,7 @@ sync_idle_cb_update_sync (RBMediaPlayerSource *source)
{
RBMediaPlayerSourcePrivate *priv = MEDIA_PLAYER_SOURCE_GET_PRIVATE (source);
- if (priv->sync_needs_update) {
- update_sync (source);
- }
+ update_sync (source);
/* Check we have enough space on the device. */
if (priv->sync_space_needed > get_capacity (source)) {
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]