private void UpdateDimension() { this._parentRect = new RECT(); GetWindowRect(this._parentWindow, out this._parentRect); if (((this._parentRect.Left != this._oldParentRect.Left) || (this._parentRect.Top != this._oldParentRect.Top)) || ((this._parentRect.Right != this._oldParentRect.Right) || (this._parentRect.Bottom != this._oldParentRect.Bottom))) { base.Invoke(new EventHandler(delegate { SetWindowPos(base.Handle, 0, this._parentRect.Left, this._parentRect.Top, this._parentRect.Right - this._parentRect.Left, this._parentRect.Bottom - this._parentRect.Top, 0); Program.Pubg.SetDimension(this._parentRect.Right - this._parentRect.Left, this._parentRect.Bottom - this._parentRect.Top); })); } this._oldParentRect = this._parentRect; }
private static extern bool GetWindowRect(IntPtr hWnd, out PGVisual.Overlay.Overlay.RECT lpRect);