Add another hook.
This commit is contained in:
parent
0905e88f70
commit
2da1352c75
|
@ -1938,6 +1938,20 @@ _FX BOOL Gui_MoveWindow(
|
|||
SetLastError(ERROR_INVALID_WINDOW_HANDLE);
|
||||
return FALSE;
|
||||
}
|
||||
if (SbieApi_QueryConfBool(NULL, L"BlockInterferenceControl", FALSE)) {
|
||||
RECT rt;
|
||||
typedef (*P_SystemParametersInfoA)(UINT uiAction,
|
||||
UINT uiParam,
|
||||
PVOID pvParam,
|
||||
UINT fWinIni);
|
||||
typedef (*P_GetSystemMetrics)(int nIndex);
|
||||
P_SystemParametersInfoA SystemParametersInfoA = Ldr_GetProcAddrNew("user32.dll", "SystemParametersInfoA", "SystemParametersInfoA"); if (!SystemParametersInfoA) goto then;
|
||||
P_GetSystemMetrics GetSystemMetrics = Ldr_GetProcAddrNew("user32.dll", "GetSystemMetrics", "GetSystemMetrics"); if (!GetSystemMetrics) goto then;
|
||||
SystemParametersInfoA(SPI_GETWORKAREA, 0, &rt, 0);
|
||||
int y1 = GetSystemMetrics(SM_CYSCREEN) - rt.bottom;
|
||||
if (y + h > y1)
|
||||
h = y1 - y - GetSystemMetrics(4);
|
||||
}
|
||||
return __sys_MoveWindow(hWnd, x, y, w, h, bRepaint);
|
||||
}
|
||||
|
||||
|
@ -1974,7 +1988,7 @@ _FX BOOL Gui_SetWindowPos(
|
|||
SystemParametersInfoA(SPI_GETWORKAREA, 0, &rt, 0);
|
||||
int y1 = GetSystemMetrics(SM_CYSCREEN) - rt.bottom;
|
||||
if (y+h > y1)
|
||||
h = y1-y;
|
||||
h = y1-y - GetSystemMetrics(4);
|
||||
}
|
||||
then:
|
||||
if (Gui_UseProxyService && !Gui_IsSameBox(hWnd, NULL, NULL)) {
|
||||
|
|
Loading…
Reference in New Issue