diff --git a/README.md b/README.md index afcff99..4f20c51 100644 --- a/README.md +++ b/README.md @@ -70,6 +70,10 @@ https://github.com/stax76/mpv.net/wiki/Scripting-(CSharp,-Python,-JavaScript,-Lu ### Changelog +### 2.9 (2019- + +- clicking the right top corner in fullscreen mode closes the player but it did not work on all displays + ### 2.8 (2019-04-12) - Win 7 dark-mode render issue fix diff --git a/mpv.net/MainForm.cs b/mpv.net/MainForm.cs index 525642f..bf3dff1 100644 --- a/mpv.net/MainForm.cs +++ b/mpv.net/MainForm.cs @@ -378,11 +378,7 @@ namespace mpvnet Native.PostMessage(Handle, 0xA1 /* WM_NCLBUTTONDOWN */, HTCAPTION, IntPtr.Zero); } - var sb = Screen.FromControl(this).Bounds; - var p1 = new Point(sb.Width, 0); - var p2 = PointToScreen(e.Location); - - if (Math.Abs(p1.X - p2.X) < 10 && Math.Abs(p1.Y - p2.Y) < 10) + if (Width - e.Location.X < 10 && e.Location.Y < 10) mp.commandv("quit"); } diff --git a/screenshots/mpvConfEdit.png b/screenshots/mpvConfEdit.png index 71b5c3a..6fb4491 100644 Binary files a/screenshots/mpvConfEdit.png and b/screenshots/mpvConfEdit.png differ