mirror of
https://github.com/isledecomp/isle-portable.git
synced 2025-09-24 21:29:41 -04:00
Implement SetWindowPos (#98)
This commit is contained in:
parent
4ada014dfd
commit
d58ce5e9a9
@ -16,7 +16,7 @@
|
||||
#define CALLBACK
|
||||
#define FAR
|
||||
#define WINAPI
|
||||
#define HWND_NOTOPMOST (HWND) - 2
|
||||
#define HWND_NOTOPMOST -2
|
||||
#define RGB(r, g, b) ((r) | ((g) << 8) | ((b) << 16))
|
||||
#define S_OK ((HRESULT) 0)
|
||||
#define E_NOINTERFACE (0x80004002)
|
||||
@ -147,10 +147,7 @@ private:
|
||||
int m_refCount;
|
||||
};
|
||||
|
||||
inline BOOL SetWindowPos(HWND hWnd, HWND hWndInsertAfter, int X, int Y, int cx, int cy, UINT uFlags)
|
||||
{
|
||||
return TRUE;
|
||||
}
|
||||
BOOL SetWindowPos(HWND hWnd, int hWndInsertAfter, int X, int Y, int cx, int cy, UINT uFlags);
|
||||
|
||||
inline HDC WINAPI GetDC(HWND hWnd)
|
||||
{
|
||||
|
@ -24,6 +24,27 @@ HRESULT IUnknown::QueryInterface(const GUID& riid, void** ppvObject)
|
||||
return E_NOINTERFACE;
|
||||
}
|
||||
|
||||
BOOL SetWindowPos(HWND hWnd, int hWndInsertAfter, int X, int Y, int cx, int cy, UINT uFlags)
|
||||
{
|
||||
if (!hWnd) {
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
if (!(uFlags & SWP_NOACTIVATE)) {
|
||||
SDL_RaiseWindow(hWnd);
|
||||
}
|
||||
|
||||
if (!(uFlags & SWP_NOSIZE)) {
|
||||
SDL_SetWindowSize(hWnd, cx, cy);
|
||||
}
|
||||
|
||||
if (!(uFlags & SWP_NOMOVE)) {
|
||||
SDL_SetWindowPosition(hWnd, X, Y);
|
||||
}
|
||||
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
VOID WINAPI Sleep(DWORD dwMilliseconds)
|
||||
{
|
||||
SDL_Delay(dwMilliseconds);
|
||||
|
Loading…
x
Reference in New Issue
Block a user