using DevExpress.XtraEditors; using System; using System.Windows.Forms; namespace HL_FristAidPlatform_RealTimeVideo { public partial class Form_RealTimeVideo_FullScreen : XtraForm { /// /// 要显示的控件 /// 用于回调 /// public Control Control; /// /// 全屏显示 /// /// 要显示的控件 public Form_RealTimeVideo_FullScreen(Control control) { InitializeComponent(); Control = control; this.Controls.Add(Control); } /// /// 关闭按钮 /// 此方法内禁止调试,否则会黑屏 /// /// /// private void btn_Close_Click(object sender, EventArgs e) { this.Close(); this.DialogResult = DialogResult.OK; this.Dispose(); } /// /// 按下ESC退出 /// 此方法内禁止调试,否则会黑屏 /// /// /// private void Form_RealTimeVideo_FullScreen_KeyDown(object sender, KeyEventArgs e) { if (e.KeyCode == Keys.Escape) { this.Close(); this.DialogResult = DialogResult.OK; this.Dispose(); } } } }