[pitivi] mainwindow: Let the medialibrary clean after itself



commit 885605f8fffbd3241597c8dd47875691cd8a2ed5
Author: Alexandru Băluț <alexandru balut gmail com>
Date:   Sun Feb 14 00:34:57 2016 +0100

    mainwindow: Let the medialibrary clean after itself
    
    Differential Revision: https://phabricator.freedesktop.org/D772

 pitivi/mainwindow.py   |    3 +--
 pitivi/medialibrary.py |    1 +
 2 files changed, 2 insertions(+), 2 deletions(-)
---
diff --git a/pitivi/mainwindow.py b/pitivi/mainwindow.py
index 8ed030e..8960a0f 100644
--- a/pitivi/mainwindow.py
+++ b/pitivi/mainwindow.py
@@ -857,8 +857,7 @@ class PitiviMainWindow(Gtk.ApplicationWindow, Loggable):
         if project.pipeline is not None:
             project.pipeline.deactivatePositionListener()
 
-        self.info("Project closed - clearing the media library and timeline")
-        self.medialibrary.storemodel.clear()
+        self.info("Project closed")
         self._disconnectFromProject(project)
         self.timeline_ui.setProject(None)
         self.render_button.set_sensitive(False)
diff --git a/pitivi/medialibrary.py b/pitivi/medialibrary.py
index 20756e2..5011031 100644
--- a/pitivi/medialibrary.py
+++ b/pitivi/medialibrary.py
@@ -1440,6 +1440,7 @@ class MediaLibraryWidget(Gtk.Box, Loggable):
 
     def _projectClosedCb(self, unused_project_manager, unused_project):
         self._project_settings_set_infobar.hide()
+        self.storemodel.clear()
 
     def _addUris(self, uris):
         if self.app.project_manager.current_project:


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]