Added mciavi32-fullscreen_support patchset

This commit is contained in:
Alistair Leslie-Hughes 2019-01-25 15:55:40 +11:00
parent 5e5c754a8b
commit 3a0fddb73c
3 changed files with 66 additions and 0 deletions

View File

@ -0,0 +1,46 @@
From 3010466bbbf82e2757f0d2d7774f56c184c572dd Mon Sep 17 00:00:00 2001
From: Bruno Jesus <bjesus@codeweavers.com>
Date: Thu, 3 Jan 2019 14:26:39 +1100
Subject: [PATCH] mciavi32: Add Support for MCI_MCIAVI_PLAY_FULLSCREEN
Wine-Bug: https://bugs.winehq.org/show_bug.cgi?id=15934
---
dlls/mciavi32/mciavi.c | 15 +++++++++++++--
1 file changed, 13 insertions(+), 2 deletions(-)
diff --git a/dlls/mciavi32/mciavi.c b/dlls/mciavi32/mciavi.c
index b32accb..9aa6cd8 100644
--- a/dlls/mciavi32/mciavi.c
+++ b/dlls/mciavi32/mciavi.c
@@ -556,7 +556,7 @@ static DWORD MCIAVI_mciPlay(UINT wDevID, DWORD dwFlags, LPMCI_PLAY_PARMS lpParms
if (dwFlags & MCI_DGV_PLAY_REVERSE) return MCIERR_UNSUPPORTED_FUNCTION;
if (dwFlags & MCI_TEST) return 0;
- if (dwFlags & (MCI_MCIAVI_PLAY_WINDOW|MCI_MCIAVI_PLAY_FULLSCREEN|MCI_MCIAVI_PLAY_FULLBY2))
+ if (dwFlags & (MCI_MCIAVI_PLAY_WINDOW|MCI_MCIAVI_PLAY_FULLBY2))
FIXME("Unsupported flag %08x\n", dwFlags);
EnterCriticalSection(&wma->cs);
@@ -591,7 +591,18 @@ static DWORD MCIAVI_mciPlay(UINT wDevID, DWORD dwFlags, LPMCI_PLAY_PARMS lpParms
LeaveCriticalSection(&wma->cs);
- if (!(GetWindowLongW(wma->hWndPaint, GWL_STYLE) & WS_VISIBLE))
+ if (dwFlags & MCI_MCIAVI_PLAY_FULLSCREEN)
+ {
+ HMONITOR mon = MonitorFromWindow(wma->hWndPaint, MONITOR_DEFAULTTONEAREST);
+ MONITORINFO mi;
+ mi.cbSize = sizeof(mi);
+ GetMonitorInfoA(mon, &mi);
+ wma->hWndPaint = CreateWindowA("STATIC", NULL, WS_POPUP | WS_VISIBLE, mi.rcMonitor.left,
+ mi.rcMonitor.top, mi.rcMonitor.right - mi.rcMonitor.left, mi.rcMonitor.bottom - mi.rcMonitor.top,
+ NULL, NULL, NULL, 0);
+ }
+ /* if not fullscreen ensure the window is visible */
+ else if (!(GetWindowLongW(wma->hWndPaint, GWL_STYLE) & WS_VISIBLE))
ShowWindow(wma->hWndPaint, SW_SHOWNA);
EnterCriticalSection(&wma->cs);
--
1.9.1

View File

@ -0,0 +1 @@
Fixes: [15934] mciavi32: Add Support for MCI_MCIAVI_PLAY_FULLSCREEN

View File

@ -172,6 +172,7 @@ patch_enable_all ()
enable_krnl386_exe16_Invalid_Console_Handles="$1"
enable_libs_Debug_Channel="$1"
enable_libs_Unicode_Collation="$1"
enable_mciavi32_fullscreen_support="$1"
enable_mf_MFCreateSequencerSource="$1"
enable_mfplat_MFGetSystemTime="$1"
enable_mmsystem_dll16_MIDIHDR_Refcount="$1"
@ -677,6 +678,9 @@ patch_enable ()
libs-Unicode_Collation)
enable_libs_Unicode_Collation="$2"
;;
mciavi32-fullscreen_support)
enable_mciavi32_fullscreen_support="$2"
;;
mf-MFCreateSequencerSource)
enable_mf_MFCreateSequencerSource="$2"
;;
@ -4070,6 +4074,21 @@ if test "$enable_libs_Unicode_Collation" -eq 1; then
) >> "$patchlist"
fi
# Patchset mciavi32-fullscreen_support
# |
# | This patchset fixes the following Wine bugs:
# | * [#15934] mciavi32: Add Support for MCI_MCIAVI_PLAY_FULLSCREEN
# |
# | Modified files:
# | * dlls/mciavi32/mciavi.c
# |
if test "$enable_mciavi32_fullscreen_support" -eq 1; then
patch_apply mciavi32-fullscreen_support/0001-mciavi32-Add-Support-for-MCI_MCIAVI_PLAY_FULLSCREEN.patch
(
printf '%s\n' '+ { "Bruno Jesus", "mciavi32: Add Support for MCI_MCIAVI_PLAY_FULLSCREEN.", 1 },';
) >> "$patchlist"
fi
# Patchset mf-MFCreateSequencerSource
# |
# | This patchset fixes the following Wine bugs: