Ejemplo n.º 1
0
        private static List <FavoriteConfigurationElement> ImportItemsFromFile(IPersistence persistence, string path,
                                                                               string fileName = DUPLICIT_ITEMS_FILE)
        {
            string fullFileName = Path.Combine(path, fileName);
            var    importers    = new Importers(persistence);

            return(importers.ImportFavorites(fullFileName));
        }
Ejemplo n.º 2
0
        private void DropFiles(Form parentForm)
        {
            var files = this.data.GetData(DataFormats.FileDrop) as String[];

            if (files == null)
            {
                return;
            }

            var importers = new Importers(this.persistence);
            var toImport  = importers.ImportFavorites(files);

            this.ApplyTargetGroup(toImport);
            var managedImport = new ImportWithDialogs(parentForm, this.persistence, this.connectinManager);

            managedImport.Import(toImport);
        }