brasero r1830 - in trunk: . libbrasero-media src src/plugins/transcode
- From: philippr svn gnome org
- To: svn-commits-list gnome org
- Subject: brasero r1830 - in trunk: . libbrasero-media src src/plugins/transcode
- Date: Sun, 25 Jan 2009 14:33:31 +0000 (UTC)
Author: philippr
Date: Sun Jan 25 14:33:31 2009
New Revision: 1830
URL: http://svn.gnome.org/viewvc/brasero?rev=1830&view=rev
Log:
2009-01-25 Philippe Rouquier <ykw localhost localdomain>
Fixed memleaks
* libbrasero-media/brasero-drive-selection.c
(brasero_drive_selection_show_type),
(brasero_drive_selection_drive_added_cb),
(brasero_drive_selection_drive_removed_cb):
* libbrasero-media/brasero-gio-operation.c
(brasero_gio_operation_umount):
* libbrasero-media/brasero-medium-selection.c
(brasero_medium_selection_show_media_type),
(brasero_medium_selection_medium_added_cb):
* src/main.c (brasero_handle_burn_uri):
* src/plugins/transcode/burn-normalize.c
(brasero_normalize_export_caps):
* src/plugins/transcode/burn-vob.c (brasero_vob_export_caps):
Modified:
trunk/ChangeLog
trunk/libbrasero-media/brasero-drive-selection.c
trunk/libbrasero-media/brasero-gio-operation.c
trunk/libbrasero-media/brasero-medium-selection.c
trunk/src/brasero-burn-dialog.c
trunk/src/brasero-jacket-edit.c
trunk/src/brasero-jacket-edit.h
trunk/src/brasero-project-manager.c
trunk/src/main.c
trunk/src/plugins/transcode/burn-normalize.c
trunk/src/plugins/transcode/burn-vob.c
Modified: trunk/libbrasero-media/brasero-drive-selection.c
==============================================================================
--- trunk/libbrasero-media/brasero-drive-selection.c (original)
+++ trunk/libbrasero-media/brasero-drive-selection.c Sun Jan 25 14:33:31 2009
@@ -338,6 +338,7 @@
ICON_COL, drive_icon,
-1);
g_free (drive_name);
+ g_object_unref (drive_icon);
}
g_slist_foreach (list, (GFunc) g_object_unref, NULL);
g_slist_free (list);
@@ -432,6 +433,7 @@
ICON_COL, drive_icon,
-1);
g_free (drive_name);
+ g_object_unref (drive_icon);
gtk_widget_set_sensitive (GTK_WIDGET (self), TRUE);
if (gtk_combo_box_get_active (GTK_COMBO_BOX (self)) == -1) {
@@ -444,7 +446,7 @@
brasero_drive_selection_drive_removed_cb (BraseroMediumMonitor *monitor,
BraseroDrive *drive,
BraseroDriveSelection *self)
- {
+{
GtkTreeModel *model;
GtkTreeIter iter;
Modified: trunk/libbrasero-media/brasero-gio-operation.c
==============================================================================
--- trunk/libbrasero-media/brasero-gio-operation.c (original)
+++ trunk/libbrasero-media/brasero-gio-operation.c Sun Jan 25 14:33:31 2009
@@ -205,7 +205,7 @@
GMount *mount;
gboolean result;
- BRASERO_MEDIA_LOG ("Unmounting volume %s", g_volume_get_name (gvolume));
+ BRASERO_MEDIA_LOG ("Unmounting volume");
if (!gvolume) {
BRASERO_MEDIA_LOG ("No volume");
Modified: trunk/libbrasero-media/brasero-medium-selection.c
==============================================================================
--- trunk/libbrasero-media/brasero-medium-selection.c (original)
+++ trunk/libbrasero-media/brasero-medium-selection.c Sun Jan 25 14:33:31 2009
@@ -487,6 +487,7 @@
ICON_COL, medium_icon,
-1);
g_free (medium_name);
+ g_object_unref (medium_icon);
}
g_slist_foreach (list, (GFunc) g_object_unref, NULL);
g_slist_free (list);
@@ -623,6 +624,7 @@
ICON_COL, medium_icon,
-1);
g_free (medium_name);
+ g_object_unref (medium_icon);
gtk_widget_set_sensitive (GTK_WIDGET (self), TRUE);
if (gtk_combo_box_get_active (GTK_COMBO_BOX (self)) == -1) {
Modified: trunk/src/brasero-burn-dialog.c
==============================================================================
--- trunk/src/brasero-burn-dialog.c (original)
+++ trunk/src/brasero-burn-dialog.c Sun Jan 25 14:33:31 2009
@@ -1750,13 +1750,13 @@
answer = gtk_dialog_run (GTK_DIALOG (dialog));
if (answer == GTK_RESPONSE_CLOSE) {
- GtkWidget *contents;
+ BraseroJacketEdit *contents;
GValue *cover_value;
const gchar *title;
GtkWidget *window;
GSList *tracks;
- contents = brasero_jacket_edit_dialog_new (GTK_WIDGET (dialog), &window);
+ window = brasero_jacket_edit_dialog_new (GTK_WIDGET (dialog), &contents);
title = brasero_burn_session_get_label (dialog->priv->session);
tracks = brasero_burn_session_get_tracks (dialog->priv->session);
@@ -1766,13 +1766,13 @@
BRASERO_COVER_URI,
&cover_value);
- brasero_jacket_edit_set_audio_tracks (BRASERO_JACKET_EDIT (contents),
+ brasero_jacket_edit_set_audio_tracks (contents,
title,
cover_value? g_value_get_string (cover_value):NULL,
tracks);
gtk_dialog_run (GTK_DIALOG (window));
-
+ gtk_widget_destroy (window);
return FALSE;
}
Modified: trunk/src/brasero-jacket-edit.c
==============================================================================
--- trunk/src/brasero-jacket-edit.c (original)
+++ trunk/src/brasero-jacket-edit.c Sun Jan 25 14:33:31 2009
@@ -99,7 +99,10 @@
BraseroJacketEdit *self)
{
BraseroJacketEditPrivate *priv;
- GtkPrintOperation *print;
+ GtkPrintOperationResult res;
+ GtkPrintOperation *print;
+ GError *error = NULL;
+ GtkWidget *toplevel;
priv = BRASERO_JACKET_EDIT_PRIVATE (self);
print = gtk_print_operation_new ();
@@ -111,10 +114,13 @@
"begin-print",
G_CALLBACK (brasero_jacket_edit_print_begin),
self);
- gtk_print_operation_run (print,
- GTK_PRINT_OPERATION_ACTION_PRINT_DIALOG,
- GTK_WINDOW (gtk_widget_get_toplevel (GTK_WIDGET (self))),
- NULL);
+
+ toplevel = gtk_widget_get_toplevel (GTK_WIDGET (self));
+ res = gtk_print_operation_run (print,
+ GTK_PRINT_OPERATION_ACTION_PRINT_DIALOG,
+ GTK_WINDOW (toplevel),
+ &error);
+ g_object_unref (print);
}
static void
@@ -886,7 +892,7 @@
GtkWidget *
brasero_jacket_edit_dialog_new (GtkWidget *toplevel,
- GtkWidget **dialog)
+ BraseroJacketEdit **contents_ret)
{
GtkWidget *window;
GtkWidget *contents;
@@ -899,22 +905,15 @@
GTK_STOCK_CLOSE, GTK_RESPONSE_CLOSE,
NULL);
+ gtk_window_set_type_hint (GTK_WINDOW (window), GDK_WINDOW_TYPE_HINT_NORMAL);
gtk_window_set_default_size (GTK_WINDOW (window), 680, 640);
- gtk_window_set_position (GTK_WINDOW (window), GTK_WIN_POS_CENTER_ON_PARENT);
- g_signal_connect (window,
- "response",
- G_CALLBACK (gtk_widget_destroy),
- NULL);
-
contents = brasero_jacket_edit_new ();
gtk_widget_show (contents);
gtk_box_pack_start (GTK_BOX (GTK_DIALOG (window)->vbox), contents, TRUE, TRUE, 0);
- gtk_widget_show (window);
-
- if (dialog)
- *dialog = window;
+ if (contents_ret)
+ *contents_ret = BRASERO_JACKET_EDIT (contents);
- return contents;
+ return window;
}
Modified: trunk/src/brasero-jacket-edit.h
==============================================================================
--- trunk/src/brasero-jacket-edit.h (original)
+++ trunk/src/brasero-jacket-edit.h Sun Jan 25 14:33:31 2009
@@ -56,7 +56,7 @@
GtkWidget *
brasero_jacket_edit_dialog_new (GtkWidget *toplevel,
- GtkWidget **dialog);
+ BraseroJacketEdit **contents);
void
brasero_jacket_edit_set_audio_tracks (BraseroJacketEdit *self,
Modified: trunk/src/brasero-project-manager.c
==============================================================================
--- trunk/src/brasero-project-manager.c (original)
+++ trunk/src/brasero-project-manager.c Sun Jan 25 14:33:31 2009
@@ -213,15 +213,20 @@
brasero_project_manager_new_cover_cb (GtkAction *action,
BraseroProjectManager *manager)
{
+ BraseroJacketEdit *edit;
GtkWidget *toplevel;
- GtkWidget *edit;
+ GtkWidget *dialog;
toplevel = gtk_widget_get_toplevel (GTK_WIDGET (manager));
- edit = brasero_jacket_edit_dialog_new (toplevel, NULL);
+ dialog = NULL;
+
+ dialog = brasero_jacket_edit_dialog_new (toplevel, &edit);
if (manager->priv->type == BRASERO_PROJECT_TYPE_AUDIO)
- brasero_project_set_cover_specifics (BRASERO_PROJECT (manager->priv->project),
- BRASERO_JACKET_EDIT (edit));
+ brasero_project_set_cover_specifics (BRASERO_PROJECT (manager->priv->project), edit);
+
+ gtk_dialog_run (GTK_DIALOG (dialog));
+ gtk_widget_destroy (dialog);
}
static void
Modified: trunk/src/main.c
==============================================================================
--- trunk/src/main.c (original)
+++ trunk/src/main.c Sun Jan 25 14:33:31 2009
@@ -220,8 +220,10 @@
return;
}
- while ((info = g_file_enumerator_next_file (enumerator, NULL, &error)))
+ while ((info = g_file_enumerator_next_file (enumerator, NULL, &error)) != NULL) {
list = g_slist_prepend (list, g_strconcat ("burn:///", g_file_info_get_name (info), NULL));
+ g_object_unref (info);
+ }
g_object_unref (enumerator);
g_object_unref (file);
Modified: trunk/src/plugins/transcode/burn-normalize.c
==============================================================================
--- trunk/src/plugins/transcode/burn-normalize.c (original)
+++ trunk/src/plugins/transcode/burn-normalize.c Sun Jan 25 14:33:31 2009
@@ -573,7 +573,6 @@
"\"Rgvolume\"");
return BRASERO_BURN_ERR;
}
-
gst_object_unref (element);
element = gst_element_factory_make ("rganalysis", NULL);
@@ -582,7 +581,6 @@
"\"Rganalysis\"");
return BRASERO_BURN_ERR;
}
-
gst_object_unref (element);
input = brasero_caps_audio_new (BRASERO_PLUGIN_IO_ACCEPT_FILE,
Modified: trunk/src/plugins/transcode/burn-vob.c
==============================================================================
--- trunk/src/plugins/transcode/burn-vob.c (original)
+++ trunk/src/plugins/transcode/burn-vob.c Sun Jan 25 14:33:31 2009
@@ -1182,19 +1182,21 @@
element = gst_element_factory_make ("ffenc_mpeg2video", NULL);
if (!element)
return BRASERO_BURN_ERR;
+ gst_object_unref (element);
element = gst_element_factory_make ("ffenc_ac3", NULL);
if (!element)
return BRASERO_BURN_ERR;
+ gst_object_unref (element);
element = gst_element_factory_make ("ffenc_mp2", NULL);
if (!element)
return BRASERO_BURN_ERR;
+ gst_object_unref (element);
element = gst_element_factory_make ("mplex", NULL);
if (!element)
return BRASERO_BURN_ERR;
-
gst_object_unref (element);
brasero_plugin_define (plugin,
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]