brasero r1919 - in trunk: . src
- From: philippr svn gnome org
- To: svn-commits-list gnome org
- Subject: brasero r1919 - in trunk: . src
- Date: Sun, 15 Feb 2009 19:56:48 +0000 (UTC)
Author: philippr
Date: Sun Feb 15 19:56:48 2009
New Revision: 1919
URL: http://svn.gnome.org/viewvc/brasero?rev=1919&view=rev
Log:
2009-02-15 Philippe Rouquier <ykw localhost localdomain>
Fix #571776 â [regression] No possible to set media title when using the replacing nautilus-cd-burner
Add possibility to set a volume name when started from nautilus
* src/brasero-disc-option-dialog.c
(brasero_disc_option_dialog_add_data_options),
(brasero_disc_option_dialog_get_session):
* src/brasero-project.c (brasero_project_burn):
Modified:
trunk/ChangeLog
trunk/src/brasero-disc-option-dialog.c
trunk/src/brasero-project.c
Modified: trunk/src/brasero-disc-option-dialog.c
==============================================================================
--- trunk/src/brasero-disc-option-dialog.c (original)
+++ trunk/src/brasero-disc-option-dialog.c Sun Feb 15 19:56:48 2009
@@ -50,6 +50,9 @@
#include "brasero-utils.h"
#include "brasero-burn-options.h"
+/* This is only used when called through other apps */
+#include "brasero-project-name.h"
+#include "brasero-app.h"
G_DEFINE_TYPE (BraseroDiscOptionDialog, brasero_disc_option_dialog, BRASERO_TYPE_BURN_OPTIONS);
@@ -57,6 +60,8 @@
BraseroBurnCaps *caps;
BraseroDisc *disc;
+ GtkWidget *label;
+
GtkWidget *joliet_toggle;
GtkWidget *video_options;
@@ -390,14 +395,29 @@
priv = BRASERO_DISC_OPTION_DIALOG_PRIVATE (dialog);
-
- /* create the options */
+ /* create the options box */
widget = gtk_vbox_new (FALSE, 0);
brasero_burn_options_add_options (BRASERO_BURN_OPTIONS (dialog), widget);
+ if (!brasero_app_is_running (brasero_app_get_default ())) {
+ /* Add the volume name widget but if and only if there isn't any
+ * label already set in the BraseroBurnSession object. */
+
+ priv->label = brasero_project_name_new ();
+ brasero_project_name_set_type (BRASERO_PROJECT_NAME (priv->label),
+ BRASERO_PROJECT_TYPE_DATA);
+
+ string = g_strdup_printf ("<b>%s</b>", _("Disc name"));
+ options = brasero_utils_pack_properties (string,
+ priv->label,
+ NULL);
+ g_free (string);
+
+ gtk_box_pack_start (GTK_BOX (widget), options, FALSE, FALSE, 0);
+ }
+
/* general options */
brasero_disc_option_dialog_joliet_widget (dialog);
-
string = g_strdup_printf ("<b>%s</b>", _("Disc options"));
options = brasero_utils_pack_properties (string,
priv->joliet_toggle,
@@ -777,6 +797,14 @@
session = brasero_burn_options_get_session (BRASERO_BURN_OPTIONS (self));
brasero_disc_set_session_contents (priv->disc, session);
+
+ if (priv->label) {
+ const gchar *label;
+
+ label = gtk_entry_get_text (GTK_ENTRY (priv->label));
+ brasero_burn_session_set_label (session, label);
+ }
+
return session;
}
Modified: trunk/src/brasero-project.c
==============================================================================
--- trunk/src/brasero-project.c (original)
+++ trunk/src/brasero-project.c Sun Feb 15 19:56:48 2009
@@ -937,8 +937,14 @@
session = brasero_disc_option_dialog_get_session (BRASERO_DISC_OPTION_DIALOG (dialog));
gtk_widget_destroy (dialog);
- /* set the label/cover for the session */
- brasero_burn_session_set_label (session, gtk_entry_get_text (GTK_ENTRY (project->priv->name_display)));
+ if (brasero_app_is_running (brasero_app_get_default ())) {
+ const gchar *label;
+
+ /* Set the label for the session but only if we weren't started
+ * to burn a project (like through nautilus). */
+ label = gtk_entry_get_text (GTK_ENTRY (project->priv->name_display));
+ brasero_burn_session_set_label (session, label);
+ }
if (project->priv->cover) {
GValue *value;
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]