09-27
This commit is contained in:
40
SubProject/FCOMMON/fBase.cs
Normal file
40
SubProject/FCOMMON/fBase.cs
Normal file
@@ -0,0 +1,40 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.ComponentModel;
|
||||
using System.Data;
|
||||
using System.Drawing;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Windows.Forms;
|
||||
|
||||
namespace FCOMMON
|
||||
{
|
||||
public partial class fBase : Form
|
||||
{
|
||||
public fBase()
|
||||
{
|
||||
InitializeComponent();
|
||||
this.FormClosed += fBase_FormClosed;
|
||||
this.KeyDown += fBase_KeyDown;
|
||||
}
|
||||
|
||||
void fBase_KeyDown(object sender, KeyEventArgs e)
|
||||
{
|
||||
if (e.KeyCode == Keys.Escape) this.Close();
|
||||
}
|
||||
|
||||
void fBase_FormClosed(object sender, FormClosedEventArgs e)
|
||||
{
|
||||
var form = this as Form;
|
||||
FCOMMON.Util.SetFormStatus(ref form, this.Name, false);
|
||||
}
|
||||
|
||||
private void fBase_Load(object sender, EventArgs e)
|
||||
{
|
||||
var form = this as Form;
|
||||
FCOMMON.Util.SetFormStatus(ref form, this.Name, true);
|
||||
this.Show();
|
||||
Application.DoEvents();
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user