[vlc-commits] vout:win32: no need to handle the position in CommonManage
Steve Lhomme
git at videolan.org
Mon Apr 1 16:50:22 CEST 2019
vlc | branch: master | Steve Lhomme <robux4 at ycbcr.xyz> | Mon Mar 25 16:28:40 2019 +0100| [d563ab2c976278ae09d6e9e9a98f4c987c35a7c0] | committer: Steve Lhomme
vout:win32: no need to handle the position in CommonManage
We don't care about the child position compared to its parent so we don't need
it to check if the size have changed or not.
> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=d563ab2c976278ae09d6e9e9a98f4c987c35a7c0
---
modules/video_output/win32/common.c | 7 ++-----
1 file changed, 2 insertions(+), 5 deletions(-)
diff --git a/modules/video_output/win32/common.c b/modules/video_output/win32/common.c
index 8e742a0e88..676ccb49f4 100644
--- a/modules/video_output/win32/common.c
+++ b/modules/video_output/win32/common.c
@@ -252,15 +252,12 @@ void CommonManage(vout_display_t *vd, vout_display_sys_win32_t *sys)
* ourselves because the parent might not send us its events. */
if (sys->hparent) {
RECT rect_parent;
- POINT point;
/* Check if the parent window has resized or moved */
GetClientRect(sys->hparent, &rect_parent);
- point.x = point.y = 0;
- ClientToScreen(sys->hparent, &point);
- OffsetRect(&rect_parent, point.x, point.y);
- if (!EqualRect(&rect_parent, &sys->rect_parent)) {
+ if (RECTWidth(rect_parent) != RECTWidth(sys->rect_parent) ||
+ RECTHeight(rect_parent) != RECTHeight(sys->rect_parent)) {
sys->rect_parent = rect_parent;
/* This code deals with both resize and move
More information about the vlc-commits
mailing list