From ff11a818569eaed1a2c0c9f9249404697886be54 Mon Sep 17 00:00:00 2001 From: Hylke Bons Date: Sun, 21 Nov 2010 19:41:30 +0000 Subject: [PATCH] [controller] Add TODO --- SparkleShare/SparkleController.cs | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/SparkleShare/SparkleController.cs b/SparkleShare/SparkleController.cs index cc69998a..3c1e28f4 100644 --- a/SparkleShare/SparkleController.cs +++ b/SparkleShare/SparkleController.cs @@ -59,7 +59,7 @@ namespace SparkleShare { public delegate void OnErrorEventHandler (); public event OnInvitationEventHandler OnInvitation; - public delegate void OnInvitationEventHandler (string server, string name, string token); + public delegate void OnInvitationEventHandler (string server, string folder, string token); public event ConflictNotificationRaisedEventHandler ConflictNotificationRaised; public delegate void ConflictNotificationRaisedEventHandler (); @@ -116,18 +116,18 @@ namespace SparkleShare { // Handle invitations when the user saves an // invitation into the SparkleShare folder - if (args.FullPath.EndsWith (".sparkle")) { - + if (args.Name.EndsWith (".sparkle")) { + XmlDocument xml_doc = new XmlDocument (); xml_doc.Load (args.Name); string server = xml_doc.GetElementsByTagName ("server") [0].InnerText; string folder = xml_doc.GetElementsByTagName ("folder") [0].InnerText; string token = xml_doc.GetElementsByTagName ("token") [0].InnerText; - + + // TODO: this is broken :\ if (OnInvitation != null) OnInvitation (server, folder, token); - } else if (Directory.Exists (Path.Combine (args.FullPath, ".git"))) {