示例#1
0
 private void ImportDiscoveredFavorites()
 {
     if (this.rdp.DiscoveredConnections.Count > 0)
     {
         String message = String.Format("Automatic Discovery was able to find {0} connections.\r\n" +
                                        "Would you like to add them to your connections list?",
                                        this.rdp.DiscoveredConnections.Count);
         if (MessageBox.Show(message, "Terminals Confirmation", MessageBoxButtons.YesNo) == DialogResult.Yes)
         {
             List <FavoriteConfigurationElement> favoritesToImport = this.rdp.DiscoveredConnections.ToList();
             var managedImport = new ImportWithDialogs(this, this.persistence, this.connectionManager);
             managedImport.Import(favoritesToImport);
         }
     }
 }
示例#2
0
        private void ImportSelectedItems(List <FavoriteConfigurationElement> favoritesToImport)
        {
            var managedImport = new ImportWithDialogs(this, this.persistence, this.connectionManager);

            managedImport.Import(favoritesToImport);
        }