Exemplo n.º 1
0
        static void Main()
        {
            //Application.SetUnhandledExceptionMode(UnhandledExceptionMode.ThrowException);
            //AppDomain.CurrentDomain.UnhandledException += DumpMaker.CurrentDomain_UnhandledException;
            Application.EnableVisualStyles();
            Application.SetCompatibleTextRenderingDefault(false);
            DictonariesDir = Path.Combine(Application.StartupPath, "Dictonaries");
            if (!Directory.Exists(DictonariesDir))
            {
                Directory.CreateDirectory(DictonariesDir);
            }
            TransDict    = new TranslationDictonary();
            tools        = new TextTool(Application.StartupPath);
            TessManager  = new TesseractManager();
            IconDB       = new IconManager(Application.StartupPath);
            ColorManager = new ColorSchemeManager();
            ColorManager.Load(Path.Combine(Application.StartupPath, "ColorScheme.json"));
            string testDbPath = Environment.GetFolderPath(Environment.SpecialFolder.UserProfile) + "\\Appdata\\LocalLow\\Cygames\\umamusume\\master\\master.mdb";

            if (File.Exists(testDbPath))
            {
                DbPath = testDbPath;
            }
            else
            {
                DbPath = "master.db";
            }
            DbPath = "master.db"; //временно принудительный выбор базы и папки с программой, пока есть проблемы с определением новейшей версии
            if (IsDebug)
            {
                fLog = new Form_log();
                fLog.Show();
            }
            Application.Run(new Form1());
        }
Exemplo n.º 2
0
        private void saveColorSchemeToolStripMenuItem_Click(object sender, EventArgs e)
        {
            ColorSchemeManager colorSchemeManager = new ColorSchemeManager();

            colorSchemeManager.Items.Add(ColorSchemeManager.ColorScheme.GetDefaultColorScheme());
            colorSchemeManager.Items.Add(ColorSchemeManager.ColorScheme.GetDarkDefaultColorScheme());
            colorSchemeManager.Save("testScheme.json");
            colorSchemeManager.Load("testScheme.json");
        }