[longomatch] Alwasy close the current project after SaveFakeProject



commit ebb71e8f9c89afb0ac4eae924bdf11e9b84b95ed
Author: Andoni Morales Alastruey <ylatuya gmail com>
Date:   Sun Mar 7 18:53:57 2010 +0100

    Alwasy close the current project after SaveFakeProject

 LongoMatch/Gui/MainWindow.cs |   12 ++++--------
 1 files changed, 4 insertions(+), 8 deletions(-)
---
diff --git a/LongoMatch/Gui/MainWindow.cs b/LongoMatch/Gui/MainWindow.cs
index 52d065c..69abc3a 100644
--- a/LongoMatch/Gui/MainWindow.cs
+++ b/LongoMatch/Gui/MainWindow.cs
@@ -181,8 +181,7 @@ namespace LongoMatch.Gui
 			
 			if (projectType != ProjectType.NewFileProject){
 				if (projectType == ProjectType.NewFakeCaptureProject)
-					if (!SaveFakeLiveProject(openedProject))
-						return;
+					SaveFakeLiveProject(openedProject);
 				playerbin1.Visible = true;
 				eManager.Capturer = null;
 				if (capturerBin != null)
@@ -271,15 +270,14 @@ namespace LongoMatch.Gui
 			return res;
 		}
 		
-		private bool SaveFakeLiveProject(Project project){
-			bool res = false;
+		private void SaveFakeLiveProject(Project project){
 			MessageDialog md = new MessageDialog((Gtk.Window)this.Toplevel, DialogFlags.Modal, MessageType.Question, ButtonsType.OkCancel,
-			                                     Catalog.GetString("The project will be saved to a file.You can insert it later into the database using the "+
+			                                     Catalog.GetString("The project will be saved to a file. You can insert it later into the database using the "+
 			                                                       "Import function once you copied the video file to your computer.\n"+
 			                                                       "If you cancel this action all your changes will be lost!"));			                                           
 			if (md.Run() == (int)ResponseType.Cancel){
 				md.Destroy();
-				return true;
+				return;
 			}else
 				md.Destroy();
 			                                                                       
@@ -298,10 +296,8 @@ namespace LongoMatch.Gui
 				Project.Export(project, fChooser.Filename);
 				MessagePopup.PopupMessage(this.Toplevel, MessageType.Info, 
 				                          Catalog.GetString("Project saved successfully."));			  
-				res = true;
 			}
 			fChooser.Destroy();
-			return res;
 		}
 
 		#endregion



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