Esempio n. 1
0
 void bridge_DataReceived(object sender, DataReceivedEventArgs e)
 {
     string fullPath = e.Text;
     if (fullPath.StartsWith("BRIDGE:"))
     {
         // Lets expose bridge location...
         Environment.SetEnvironmentVariable("FDBRIDGE", fullPath.Replace("BRIDGE:", ""));
         return;
     }
     if (!fullPath.EndsWith("\\")) fullPath += '\\';
     if (fullPath.Length < 3) return;
     string folder = Path.GetDirectoryName(fullPath);
     string name = Path.GetFileName(fullPath);
     if (Changed != null) Changed(this, new FileSystemEventArgs(WatcherChangeTypes.Changed, folder, name));
 }
Esempio n. 2
0
 void bridge_DataReceived(object sender, DataReceivedEventArgs e)
 {
     TraceManager.AddAsync("changed: " + e.Text);
     string fullPath = e.Text;
     if (!fullPath.EndsWith("\\")) fullPath += '\\';
     if (fullPath.Length < 3) return;
     string folder = Path.GetDirectoryName(fullPath);
     string name = Path.GetFileName(fullPath);
     if (Changed != null)
         Changed(this, new FileSystemEventArgs(WatcherChangeTypes.Changed, folder, name));
 }