示例#1
0
        private static void ShowSelectedFiles()
        {
            var fileBundle = InputCollector.CollectFileNamesToCompare();

            Console.WriteLine("{0}Selected files :{0}", "\n");
            Console.ForegroundColor = ConsoleColor.Yellow;
            fileBundle.ShowToConsoleStringsList();
            Console.ResetColor();

            Console.SetCursorPosition(0, Console.CursorTop - 1);
            Console.WriteLine("Press R to reset selected files or any other key to confirm");

            ResetSelectedFiles();

            MakeMenuVisible();
        }
示例#2
0
        private static void WriteIsolatedCompareToolFilesList(IsolatedStorageFile isolatedFile)
        {
            using (
                IsolatedStorageFileStream stream = new IsolatedStorageFileStream(
                    "CompareToolFilesList",
                    FileMode.Create,
                    isolatedFile))
            {
                using (StreamWriter sw = new StreamWriter(stream))
                {
                    List <string> fileBundle = InputCollector.CollectFileNamesToCompare();

                    foreach (string file in fileBundle)
                    {
                        sw.WriteLine(file);
                    }
                }
            }
        }
示例#3
0
        private static void SetFilesForComparing()
        {
            ConsoleOutput.ShowInstructionsForFileWithNumber(1);
            InputCollector.FirstFileName = InputCollector.SetFileName();
            ConsoleOutput.ShowInstructionsForFileWithNumber(2);
            InputCollector.SecondFileName = InputCollector.SetFileName();
            Console.WriteLine();

            if (InputCollector.FirstFileName == null || InputCollector.SecondFileName == null)
            {
                FileWriter.WriteDataToFileInIsolatedStorage(FileWriter.DataSelectionStatus = "No");
                MakeMenuVisible();
                FileWriter.IsDataSelected = false;
                return;
            }

            FileWriter.WriteDataToFileInIsolatedStorage(FileWriter.DataSelectionStatus = "Yes");

            MakeMenuVisible();

            FileWriter.IsDataSelected = true;
        }