Ejemplo n.º 1
0
 // private Dictionary<string,FileSystemWatcher> _directoriesFileSystemWatchers = new Dictionary<string, FileSystemWatcher>();
 public DirectoryWatcher(TopViewModel top,IDirectoryViewModel root, PathHelper pathHelper, Dispatcher dispatcher)
 {
     Top = top;
     _pathHelper = pathHelper;
     _dispatcher = dispatcher;
     root.SubDirectories.CollectionLoaded += SubDirectories_CollectionLoaded;
 }
Ejemplo n.º 2
0
        public MainViewModel()
        {
            _dispatcher = Dispatcher.CurrentDispatcher;
            var root = new RootDirectoryViewModel();

            Items.Add(root);
            _pathHelper           = new PathHelper(root);
            Top                   = new TopViewModel(_pathHelper);
            _directoryWatcher     = new DirectoryWatcher(Top, root, _pathHelper, Dispatcher.CurrentDispatcher);
            Top.SelectedDirectory = root;
        }