Merge remote-tracking branch 'jturney/rpavlik-xwin-fixes'
This commit is contained in:
commit
e722ad6c3e
|
@ -175,7 +175,8 @@ install-exec-hook:
|
||||||
EXTRA_DIST = \
|
EXTRA_DIST = \
|
||||||
$(xwinconfig_DATA) \
|
$(xwinconfig_DATA) \
|
||||||
X.ico \
|
X.ico \
|
||||||
XWin.rc
|
XWin.rc \
|
||||||
|
XWin.exe.manifest
|
||||||
|
|
||||||
relink:
|
relink:
|
||||||
$(AM_V_at)rm -f XWin$(EXEEXT) && $(MAKE) XWin$(EXEEXT)
|
$(AM_V_at)rm -f XWin$(EXEEXT) && $(MAKE) XWin$(EXEEXT)
|
||||||
|
|
|
@ -39,7 +39,6 @@
|
||||||
#include <sys/select.h>
|
#include <sys/select.h>
|
||||||
#else
|
#else
|
||||||
#include <X11/Xwinsock.h>
|
#include <X11/Xwinsock.h>
|
||||||
#define HAS_WINSOCK
|
|
||||||
#endif
|
#endif
|
||||||
#include <fcntl.h>
|
#include <fcntl.h>
|
||||||
#include <setjmp.h>
|
#include <setjmp.h>
|
||||||
|
|
|
@ -32,6 +32,8 @@
|
||||||
|
|
||||||
#ifdef HAVE_XWIN_CONFIG_H
|
#ifdef HAVE_XWIN_CONFIG_H
|
||||||
#include <xwin-config.h>
|
#include <xwin-config.h>
|
||||||
|
#else
|
||||||
|
#define HAS_WINSOCK 1
|
||||||
#endif
|
#endif
|
||||||
#include <sys/types.h>
|
#include <sys/types.h>
|
||||||
#include "winclipboard.h"
|
#include "winclipboard.h"
|
||||||
|
|
|
@ -192,15 +192,12 @@ winSetEngine (ScreenPtr pScreen)
|
||||||
|
|
||||||
/* ShadowGDI is the only engine that supports Multi Window Mode */
|
/* ShadowGDI is the only engine that supports Multi Window Mode */
|
||||||
if (
|
if (
|
||||||
#ifdef XWIN_MULTIWINDOWEXTWM
|
|
||||||
pScreenInfo->fMWExtWM
|
|
||||||
#else
|
|
||||||
FALSE
|
FALSE
|
||||||
|
#ifdef XWIN_MULTIWINDOWEXTWM
|
||||||
|
|| pScreenInfo->fMWExtWM
|
||||||
#endif
|
#endif
|
||||||
#ifdef XWIN_MULTIWINDOW
|
#ifdef XWIN_MULTIWINDOW
|
||||||
|| pScreenInfo->fMultiWindow
|
|| pScreenInfo->fMultiWindow
|
||||||
#else
|
|
||||||
|| FALSE
|
|
||||||
#endif
|
#endif
|
||||||
)
|
)
|
||||||
{
|
{
|
||||||
|
|
|
@ -1201,11 +1201,13 @@ winInitWM (void **ppWMInfo,
|
||||||
XMsgProcArgPtr pXMsgArg = (XMsgProcArgPtr) malloc (sizeof(XMsgProcArgRec));
|
XMsgProcArgPtr pXMsgArg = (XMsgProcArgPtr) malloc (sizeof(XMsgProcArgRec));
|
||||||
|
|
||||||
/* Bail if the input parameters are bad */
|
/* Bail if the input parameters are bad */
|
||||||
if (pArg == NULL || pWMInfo == NULL)
|
if (pArg == NULL || pWMInfo == NULL || pXMsgArg == NULL) {
|
||||||
{
|
ErrorF ("winInitWM - malloc failed.\n");
|
||||||
ErrorF ("winInitWM - malloc failed.\n");
|
free(pArg);
|
||||||
return FALSE;
|
free(pWMInfo);
|
||||||
}
|
free(pXMsgArg);
|
||||||
|
return FALSE;
|
||||||
|
}
|
||||||
|
|
||||||
/* Zero the allocated memory */
|
/* Zero the allocated memory */
|
||||||
ZeroMemory (pArg, sizeof (WMProcArgRec));
|
ZeroMemory (pArg, sizeof (WMProcArgRec));
|
||||||
|
|
|
@ -315,7 +315,6 @@ static Bool
|
||||||
winActivateAppNativeGDI (ScreenPtr pScreen)
|
winActivateAppNativeGDI (ScreenPtr pScreen)
|
||||||
{
|
{
|
||||||
winScreenPriv(pScreen);
|
winScreenPriv(pScreen);
|
||||||
winScreenInfo *pScreenInfo = pScreenPriv->pScreenInfo;
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Are we active?
|
* Are we active?
|
||||||
|
@ -323,7 +322,8 @@ winActivateAppNativeGDI (ScreenPtr pScreen)
|
||||||
*/
|
*/
|
||||||
if (pScreenPriv != NULL
|
if (pScreenPriv != NULL
|
||||||
&& pScreenPriv->fActive
|
&& pScreenPriv->fActive
|
||||||
&& pScreenInfo->fFullScreen)
|
&& pScreenPriv->pScreenInfo
|
||||||
|
&& pScreenPriv->pScreenInfo->fFullScreen)
|
||||||
{
|
{
|
||||||
/*
|
/*
|
||||||
* Activating, attempt to bring our window
|
* Activating, attempt to bring our window
|
||||||
|
@ -338,7 +338,8 @@ winActivateAppNativeGDI (ScreenPtr pScreen)
|
||||||
*/
|
*/
|
||||||
if (pScreenPriv != NULL
|
if (pScreenPriv != NULL
|
||||||
&& !pScreenPriv->fActive
|
&& !pScreenPriv->fActive
|
||||||
&& pScreenInfo->fFullScreen)
|
&& pScreenPriv->pScreenInfo
|
||||||
|
&& pScreenPriv->pScreenInfo->fFullScreen)
|
||||||
{
|
{
|
||||||
/*
|
/*
|
||||||
* Deactivating, stuff our window onto the
|
* Deactivating, stuff our window onto the
|
||||||
|
|
|
@ -461,12 +461,12 @@ static Bool
|
||||||
winActivateAppPrimaryDD (ScreenPtr pScreen)
|
winActivateAppPrimaryDD (ScreenPtr pScreen)
|
||||||
{
|
{
|
||||||
winScreenPriv(pScreen);
|
winScreenPriv(pScreen);
|
||||||
winScreenInfo *pScreenInfo = pScreenPriv->pScreenInfo;
|
|
||||||
RECT rcSrc, rcClient;
|
RECT rcSrc, rcClient;
|
||||||
HRESULT ddrval = DD_OK;
|
HRESULT ddrval = DD_OK;
|
||||||
|
|
||||||
/* Check for errors */
|
/* Check for errors */
|
||||||
if (pScreenPriv == NULL
|
if (pScreenPriv == NULL
|
||||||
|
|| pScreenPriv->pScreenInfo == NULL
|
||||||
|| pScreenPriv->pddsPrimary == NULL
|
|| pScreenPriv->pddsPrimary == NULL
|
||||||
|| pScreenPriv->pddsOffscreen == NULL)
|
|| pScreenPriv->pddsOffscreen == NULL)
|
||||||
return FALSE;
|
return FALSE;
|
||||||
|
@ -500,8 +500,8 @@ winActivateAppPrimaryDD (ScreenPtr pScreen)
|
||||||
/* Setup a source rectangle */
|
/* Setup a source rectangle */
|
||||||
rcSrc.left = 0;
|
rcSrc.left = 0;
|
||||||
rcSrc.top = 0;
|
rcSrc.top = 0;
|
||||||
rcSrc.right = pScreenInfo->dwWidth;
|
rcSrc.right = pScreenPriv->pScreenInfo->dwWidth;
|
||||||
rcSrc.bottom = pScreenInfo->dwHeight;
|
rcSrc.bottom = pScreenPriv->pScreenInfo->dwHeight;
|
||||||
|
|
||||||
ddrval = IDirectDrawSurface2_Blt (pScreenPriv->pddsPrimary,
|
ddrval = IDirectDrawSurface2_Blt (pScreenPriv->pddsPrimary,
|
||||||
&rcClient,
|
&rcClient,
|
||||||
|
|
|
@ -122,8 +122,6 @@ Bool
|
||||||
winRandRScreenSetSize (ScreenPtr pScreen,
|
winRandRScreenSetSize (ScreenPtr pScreen,
|
||||||
CARD16 width,
|
CARD16 width,
|
||||||
CARD16 height,
|
CARD16 height,
|
||||||
CARD16 pixWidth,
|
|
||||||
CARD16 pixHeight,
|
|
||||||
CARD32 mmWidth,
|
CARD32 mmWidth,
|
||||||
CARD32 mmHeight)
|
CARD32 mmHeight)
|
||||||
{
|
{
|
||||||
|
|
|
@ -270,7 +270,6 @@ winQueryRGBBitsAndMasks (ScreenPtr pScreen)
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
ErrorF ("winQueryRGBBitsAndMasks - winQueryScreenDIBFormat failed\n");
|
ErrorF ("winQueryRGBBitsAndMasks - winQueryScreenDIBFormat failed\n");
|
||||||
free (pbmih);
|
|
||||||
fReturn = FALSE;
|
fReturn = FALSE;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -551,7 +551,7 @@ winMWExtWMRestackFrame (RootlessFrameID wid, RootlessFrameID nextWid)
|
||||||
winDebug ("winMWExtWMRestackFrame (%08x)\n", (int) pRLWinPriv);
|
winDebug ("winMWExtWMRestackFrame (%08x)\n", (int) pRLWinPriv);
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
if (pScreenPriv->fRestacking) return;
|
if (pScreenPriv && pScreenPriv->fRestacking) return;
|
||||||
|
|
||||||
if (pScreenPriv) pScreenInfo = pScreenPriv->pScreenInfo;
|
if (pScreenPriv) pScreenInfo = pScreenPriv->pScreenInfo;
|
||||||
|
|
||||||
|
@ -640,8 +640,6 @@ winMWExtWMRestackFrame (RootlessFrameID wid, RootlessFrameID nextWid)
|
||||||
SetWindowPos (pRLWinPriv->hWnd, pRLNextWinPriv->hWnd,
|
SetWindowPos (pRLWinPriv->hWnd, pRLNextWinPriv->hWnd,
|
||||||
0, 0, 0, 0,
|
0, 0, 0, 0,
|
||||||
SWP_NOMOVE|SWP_NOSIZE|SWP_NOACTIVATE);
|
SWP_NOMOVE|SWP_NOSIZE|SWP_NOACTIVATE);
|
||||||
#if 0
|
|
||||||
#endif
|
|
||||||
}
|
}
|
||||||
#if CYGMULTIWINDOW_DEBUG
|
#if CYGMULTIWINDOW_DEBUG
|
||||||
winDebug ("winMWExtWMRestackFrame - done (%08x)\n", (int) pRLWinPriv);
|
winDebug ("winMWExtWMRestackFrame - done (%08x)\n", (int) pRLWinPriv);
|
||||||
|
|
|
@ -202,7 +202,8 @@ winMWExtWMDecorateWindow (HWND hwnd, LPARAM lParam)
|
||||||
/* Check if the Windows window property for our X window pointer is valid */
|
/* Check if the Windows window property for our X window pointer is valid */
|
||||||
if ((pRLWinPriv = (win32RootlessWindowPtr)GetProp (hwnd, WIN_WINDOW_PROP)) != NULL)
|
if ((pRLWinPriv = (win32RootlessWindowPtr)GetProp (hwnd, WIN_WINDOW_PROP)) != NULL)
|
||||||
{
|
{
|
||||||
pScreen = pRLWinPriv->pFrame->win->drawable.pScreen;
|
if (pRLWinPriv != NULL && pRLWinPriv->pFrame != NULL && pRLWinPriv->pFrame->win != NULL)
|
||||||
|
pScreen = pRLWinPriv->pFrame->win->drawable.pScreen;
|
||||||
if (pScreen) pScreenPriv = winGetScreenPriv(pScreen);
|
if (pScreen) pScreenPriv = winGetScreenPriv(pScreen);
|
||||||
if (pScreenPriv) pScreenInfo = pScreenPriv->pScreenInfo;
|
if (pScreenPriv) pScreenInfo = pScreenPriv->pScreenInfo;
|
||||||
if (pRLWinPriv && pScreenInfo) winMWExtWMUpdateWindowDecoration (pRLWinPriv, pScreenInfo);
|
if (pRLWinPriv && pScreenInfo) winMWExtWMUpdateWindowDecoration (pRLWinPriv, pScreenInfo);
|
||||||
|
|
Loading…
Reference in New Issue
Block a user