示例#1
0
文件: frmMain.cs 项目: vidarw/RVWorld
        public frmMain()
        {
            InitializeComponent();
            Text = $@"RomVaultX {Application.StartupPath}";

            string driveLetter = AppSettings.ReadSetting("vDriveLetter");

            if (driveLetter == null)
            {
                AppSettings.AddUpdateAppSettings("vDriveLetter", "V");

                driveLetter = AppSettings.ReadSetting("vDriveLetter");
            }
            vDriveLetter = driveLetter.ToCharArray()[0];

            addGameGrid();
            string res = Program.db.ConnectToDB();

            if (!string.IsNullOrEmpty(res))
            {
                MessageBox.Show("res", "DB Error", MessageBoxButtons.OK, MessageBoxIcon.Error);
                Close();
            }

            DatUpdate.UpdateGotTotal();
            DirTree.Setup(RvTreeRow.ReadTreeFromDB());
        }
示例#2
0
 public frmMain()
 {
     InitializeComponent();
     addGameGrid();
     DataAccessLayer.UpdateGotTotal();
     DirTree.Setup(RvTreeRow.ReadTreeFromDB());
 }
示例#3
0
 private void btnUpdateDats_Click(object sender, EventArgs e)
 {
     FrmProgressWindow progress = new FrmProgressWindow(this, "Scanning Dats", DatUpdate.UpdateDat);
     progress.ShowDialog(this);
     progress.Dispose();
     DirTree.Setup(RvTreeRow.ReadTreeFromDB());
     DatSetSelected(DirTree.Selected);
 }
示例#4
0
 private void deepReScanToolStripMenuItem_Click(object sender, EventArgs e)
 {
     FrmProgressWindow progress = new FrmProgressWindow(this, "Scanning RomRoot Files", romRootScanner.ScanFilesDeep);
     progress.ShowDialog(this);
     progress.Dispose();
     DirTree.Setup(RvTreeRow.ReadTreeFromDB());
     DatSetSelected(DirTree.Selected);
 }
示例#5
0
文件: frmMain.cs 项目: vidarw/RVWorld
        private void DoScan()
        {
            FrmProgressWindow progress = new FrmProgressWindow(this, "Scanning Files", RomScanner.ScanFiles);

            progress.ShowDialog(this);
            progress.Dispose();
            DirTree.Setup(RvTreeRow.ReadTreeFromDB());
            DatSetSelected(DirTree.Selected);
        }
示例#6
0
 private void SetExpanded(UITreeRow pTree, MouseButtons mouseB)
 {
     if (mouseB == MouseButtons.Left)
     {
         RvTreeRow.SetTreeExpanded(pTree.TRow.DirId, !pTree.TRow.Expanded);
         Setup(RvTreeRow.ReadTreeFromDB());
     }
     else
     {
         RvTreeRow.SetTreeExpandedChildren(pTree.TRow.DirId);
         Setup(RvTreeRow.ReadTreeFromDB());
     }
 }