[brasero] Fix the default name for a video project (that appeared with the default AUDIO project name)
- From: Philippe Rouquier <philippr src gnome org>
- To: svn-commits-list gnome org
- Subject: [brasero] Fix the default name for a video project (that appeared with the default AUDIO project name)
- Date: Sun, 21 Jun 2009 17:08:28 -0400 (EDT)
commit bfd4e1e8eadde373ad55f6ef437a0996a6fb9a0c
Author: Philippe Rouquier <bonfire-app wanadoo fr>
Date: Sun Jun 21 14:38:58 2009 +0200
Fix the default name for a video project (that appeared with the default AUDIO project name)
src/brasero-project-name.c | 21 +++++++++++++++++----
src/brasero-project.c | 9 +++++++++
2 files changed, 26 insertions(+), 4 deletions(-)
---
diff --git a/src/brasero-project-name.c b/src/brasero-project-name.c
index 3feb276..bb13d3c 100644
--- a/src/brasero-project-name.c
+++ b/src/brasero-project-name.c
@@ -542,6 +542,15 @@ brasero_project_name_track_added (BraseroBurnSession *session,
}
static void
+brasero_project_name_track_changed (BraseroBurnSession *session,
+ BraseroTrack *track,
+ BraseroProjectName *self)
+{
+ /* It can happen that stream tracks change */
+ brasero_project_name_session_changed (self);
+}
+
+static void
brasero_project_name_track_removed (BraseroBurnSession *session,
BraseroTrack *track,
guint former_position,
@@ -567,17 +576,21 @@ brasero_project_name_set_property (GObject *object,
priv = BRASERO_PROJECT_NAME_PRIVATE (object);
switch (property_id) {
- case PROP_SESSION: /* Readable and only writable at creation time */
+ case PROP_SESSION:
priv->session = g_object_ref (g_value_get_object (value));
- g_signal_connect (g_value_get_object (value),
+ g_signal_connect (priv->session,
"track-added",
G_CALLBACK (brasero_project_name_track_added),
object);
- g_signal_connect (g_value_get_object (value),
+ g_signal_connect (priv->session,
+ "track-changed",
+ G_CALLBACK (brasero_project_name_track_changed),
+ object);
+ g_signal_connect (priv->session,
"track-removed",
G_CALLBACK (brasero_project_name_track_removed),
object);
- g_signal_connect (g_value_get_object (value),
+ g_signal_connect (priv->session,
"flags-changed",
G_CALLBACK (brasero_project_name_flags_changed),
object);
diff --git a/src/brasero-project.c b/src/brasero-project.c
index aef985a..2c5090d 100644
--- a/src/brasero-project.c
+++ b/src/brasero-project.c
@@ -1439,6 +1439,7 @@ void
brasero_project_burn (BraseroProject *project)
{
gboolean res = FALSE;
+ BraseroDisc *current_disc;
if (!brasero_burn_session_is_dest_file (BRASERO_BURN_SESSION (project->priv->session)))
res = brasero_project_drive_properties (project);
@@ -1449,6 +1450,11 @@ brasero_project_burn (BraseroProject *project)
return;
project->priv->is_burning = 1;
+
+ current_disc = project->priv->current;
+ project->priv->current = NULL;
+ brasero_disc_set_session_contents (current_disc, NULL);
+
brasero_project_setup_session (project, BRASERO_BURN_SESSION (project->priv->session));
/* This is to stop the preview widget from playing */
@@ -1458,6 +1464,9 @@ brasero_project_burn (BraseroProject *project)
if (brasero_app_burn (brasero_app_get_default (), BRASERO_BURN_SESSION (project->priv->session)))
project->priv->burnt = TRUE;
+ project->priv->current = current_disc;
+ brasero_disc_set_session_contents (current_disc, BRASERO_BURN_SESSION (project->priv->session));
+
project->priv->is_burning = 0;
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]