Ejemplo n.º 1
0
        public static void loadTagsFromRegistry()
        {
            RegistryKey key = Registry.CurrentUser.OpenSubKey(@"SOFTWARE\Newrose\Samplify");

            if (key != null)
            {
                object dirs = NewroseLib.loadObjectFromRegistry(key, "AllTags");
                allTags.AddRange(dirs as Tag[]);
            }
        }
Ejemplo n.º 2
0
        private void addDirButton_Click(object sender, RoutedEventArgs e)
        {
            string dir = NewroseLib.userSelectDirectoryDialog();

            Activate(); //brings window to foreground after dialog
            if (dir != null)
            {
                Console.WriteLine("directory added");
                directories.Add(dir);
            }
            refreshListView();
        }
Ejemplo n.º 3
0
        /// <summary>
        /// Loads in directory information from registry
        /// </summary>
        public static void loadDirectoriesFromRegistry()
        {
            RegistryKey key = Registry.CurrentUser.OpenSubKey(@"SOFTWARE\Newrose\Samplify");

            if (key != null)
            {
                object dirs = NewroseLib.loadObjectFromRegistry(key, "Directories");
                directories.AddRange(dirs as string[]);
            }
            if (directories.Count == 0)
            {
                string dir = NewroseLib.userSelectDirectoryDialog();
                if (dir != null)
                {
                    directories.Add(dir);
                }
            }
        }
Ejemplo n.º 4
0
        public static void saveTagsToRegistry()
        {
            RegistryKey key = Registry.CurrentUser.CreateSubKey(@"SOFTWARE\Newrose\Samplify");

            NewroseLib.SaveObjectToRegistry(key, "AllTags", allTags.ToArray());
        }
Ejemplo n.º 5
0
        /// <summary>
        /// Saves the directory array to registry
        /// </summary>
        public static void saveDirectoriesToRegistry()
        {
            RegistryKey key = Registry.CurrentUser.CreateSubKey(@"SOFTWARE\Newrose\Samplify");

            NewroseLib.SaveObjectToRegistry(key, "Directories", directories.ToArray());
        }
Ejemplo n.º 6
0
 public static void deleteSampFilesInDirectories()
 {
     NewroseLib.deleteSampFilesInDirectories(directories.ToArray());
 }