From 69bb7d62a0fcb455412c48305957025f2f9a9c59 Mon Sep 17 00:00:00 2001 From: Hylke Bons Date: Thu, 5 Aug 2010 11:40:12 +0100 Subject: [PATCH] [repo] Add todo and fix syncing animation for fetching --- SparkleLib/SparkleRepo.cs | 17 +++++++++++------ 1 file changed, 11 insertions(+), 6 deletions(-) diff --git a/SparkleLib/SparkleRepo.cs b/SparkleLib/SparkleRepo.cs index d3dc900f..8a8a333b 100644 --- a/SparkleLib/SparkleRepo.cs +++ b/SparkleLib/SparkleRepo.cs @@ -218,6 +218,8 @@ namespace SparkleLib { private void Add () { + // TODO: Check whether adding files is neccassary + SparkleHelpers.DebugInfo ("Git", "[" + Name + "] Staging changes..."); Process.StartInfo.Arguments = "add --all"; @@ -271,17 +273,20 @@ namespace SparkleLib { Process.StartInfo.Arguments = "fetch"; - Process.WaitForExit (); Process.Start (); - SparkleHelpers.DebugInfo ("Git", "[" + Name + "] Changes fetched."); + Process.Exited += delegate { - args = new SparkleEventArgs ("FetchingFinished"); + SparkleHelpers.DebugInfo ("Git", "[" + Name + "] Changes fetched."); - if (FetchingFinished != null) - FetchingFinished (this, args); + args = new SparkleEventArgs ("FetchingFinished"); - Rebase (); + if (FetchingFinished != null) + FetchingFinished (this, args); + + Rebase (); + + }; } finally {