/// <summary> /// コンストラクター /// </summary> public MainWindow() { this.showSplashScreeen(); this.InitializeComponent(); this.Size = Settings.Default.Form_MainSize; this.WindowState = Settings.Default.Form_MainWndState; Common.SetAutoTabIndices(this); //タブオーダーを自動で設定する(1:Top値 -> 2:Left値) Common.EnableDoubleBuffering(this); //ダブルバッファリングの設定 //対象IEバージョンを変更して内部ブラウザーを生成する var regKey = Microsoft.Win32.Registry.CurrentUser.CreateSubKey("Software\\Microsoft\\Internet Explorer\\Main\\FeatureControl\\FEATURE_BROWSER_EMULATION"); regKey.SetValue(Path.GetFileName(Application.ExecutablePath), IEVersion, Microsoft.Win32.RegistryValueKind.DWord); #if DEBUG regKey.SetValue(Path.GetFileNameWithoutExtension(Application.ExecutablePath) + ".vshost.exe", IEVersion, Microsoft.Win32.RegistryValueKind.DWord); #endif this.manualForm = new Dialog.Common.dlgManual(); //NOTE: エディター一括:競合管理フォルダーを登録する。 this.conflictDirectories.Add(Resources.Path_Texts); this.conflictDirectories.Add(Resources.Path_Maps); this.conflictDirectories.Add(Resources.Path_DBs); //バージョンアップした場合は各種設定を引き継ぐ if (!Settings.Default._Upgraded) { Settings.Default.Upgrade(); Settings.Default._Upgraded = true; Settings.Default.Save(); } // NOTE: 固定する設定 Settings.Default.Map_SQEasyMode = false; //イベントハンドラーの登録 MainWindow.ProjectClosed += this.closedProject; MainWindow.ProjectStartupped += this.startupProject; //全データベースの各列に対してもイベントハンドラーを登録する foreach (var db in this.uctlDBEditor.DBList) { foreach (var subdb in db.Value.DBs) { foreach (DataGridViewColumn col in subdb.Columns) { if (col.Tag is DBColumnButtonToScript) { ((DBColumnButtonToScript)col.Tag).OpenScriptRequested += this.RequestOpenScriptEventHandler; } } } } }
/// <summary> /// ヘルプ:マニュアルを開く /// </summary> private void mnuManual_Click(object sender, EventArgs e) { if (this.manualForm.IsDisposed) { //破棄されているときはフォームを作り直す this.manualForm = new Dialog.Common.dlgManual(); this.manualForm.Show(this); } else if (!this.manualForm.Visible) { //インスタンスが残っているときは再表示する this.manualForm.Show(); } else { //既に表示されているときはアクティブにする this.manualForm.Activate(); } }