windows: Add SparkleShare folder to Explorer favorites

This commit is contained in:
Hylke Bons 2012-03-15 03:18:49 +00:00
parent 838bfa8d67
commit 8bff4c7b8b

View file

@ -142,7 +142,14 @@ namespace SparkleShare {
public override void AddToBookmarks ()
{
// TODO
string user_profile_path = Environment.GetFolderPath (
Environment.SpecialFolder.UserProfile);
string shortcut_path = Path.Combine (user_profile_path, "Links", "SparkleShare.lnk");
string shortcut_target = SparkleConfig.DefaultConfig.FoldersPath;
Shortcut shortcut = new Shortcut ();
shortcut.Create (shortcut_path, shortcut_target);
}