protected override void OnResize(EventArgs e) { // if valid if (ExternalProcessCaptured) { // if not minimizing && visible if (this.Height > 0 && this.Width > 0 && this.Visible) { this.MoveWindow("OnResize"); } } base.OnResize(e); }