if in ToggleFullScreen() you REM OUT
MoveWindow(gP.hGL, 0, 0, screenWidth, screenHeight, FALSE);
that works,
but then the OpenGL viewport doesn't cover the full display correctly.
Here is to code in am using now in CreateOverlay
// Create a popup GDImage overlay window
HWND CreateOverlay(IN HINSTANCE hInstance) {
RECT lpr; GetWindowRect(gP.hGL, &lpr);
DWORD dwStyle = WS_POPUP; // | WS_BORDER; // | WS_VISIBLE;
DWORD dwExStyle = WS_EX_ACCEPTFILES | WS_EX_TOOLWINDOW;
HWND hWnd = CreateWindowEx(dwExStyle, GDImageClassName, NULL, dwStyle, lpr.left, lpr.top, OVERLAY_WIDTH, Height(lpr), gP.hMain, 0, hInstance, NULL);
if (IsWindow(hWnd)) {
// Add tooltip support to the GDImage control.
HWND hTip = ZI_CreateToolTip(hWnd, L"");
if (hTip) {
SetWindowTheme(hTip, L"", L""); // Important, we must disable the Windows theme to use our own set of colors
SendMessage(hTip, TTM_SETTIPTEXTCOLOR, skGetSysColor(SKCOLOR_TIPTEXT), 0);
SendMessage(hTip, TTM_SETTIPBKCOLOR, skGetSysColor(SKCOLOR_TIPBACK), 0);
}
// Use gradient background
ZI_SetProperty(hWnd, ZI_GradientTop, ZD_ARGB(163, 127,127,127));
ZI_SetProperty(hWnd, ZI_GradientBottom, ZD_ARGB(163, 63,63,63));
ZI_DwmEnable(hWnd);
// Setup the messages to monitor
MonitorMessages(hWnd, (LONG_PTR) GDImageCallBack);
CreateColorObjects(hWnd);
}
return hWnd;
}
I have done more changes and code cleaning, but that will wait until tomorrow
