Exemple #1
0
        private void BrowseForm_Load(object sender, EventArgs e)
        {
            var info       = DetailsPropertyGrid.GetType().GetProperty("Controls");
            var collection = info.GetValue(DetailsPropertyGrid, null) as Control.ControlCollection;

            foreach (var control in collection)
            {
                var ctyp = control.GetType();
                if (ctyp.Name == "PropertyGridView")
                {
                    var prop = ctyp.GetField("labelRatio");
                    var val  = prop.GetValue(control);
                    prop.SetValue(control, 4.0); //somehow this sets the width of the property grid's label column...
                }
            }

            FolderTextBox.Text    = Settings.Default.GTAFolder;
            DataHexLineCombo.Text = "16";

            DataTextBox.SetTabStopWidth(3);

            HideTexturesTab();

            try
            {
                GTA5Keys.LoadFromPath(Settings.Default.GTAFolder);
                KeysLoaded = true;
                UpdateStatus("Ready to scan...");
            }
            catch
            {
                UpdateStatus("Keys not loaded! This should not happen.");
            }
        }
Exemple #2
0
        private void BinarySearchForm_Load(object sender, EventArgs e)
        {
            FileSearchFolderTextBox.Text = Settings.Default.CompiledScriptFolder;

            DataHexLineCombo.Text = "16";
            DataTextBox.SetTabStopWidth(3);


            if (RpfMan == null)
            {
                Task.Run(() =>
                {
                    GTA5Keys.LoadFromPath(GTAFolder.CurrentGTAFolder, Settings.Default.Key);
                    RpfMan = new RpfManager();
                    RpfMan.Init(GTAFolder.CurrentGTAFolder, UpdateStatus, UpdateStatus, false, false);
                    RPFScanComplete();
                });
            }
            else
            {
                RPFScanComplete();
            }
        }