diff options
Diffstat (limited to 'yapp/popup_history_dlg.cpp')
-rw-r--r-- | yapp/popup_history_dlg.cpp | 22 |
1 files changed, 13 insertions, 9 deletions
diff --git a/yapp/popup_history_dlg.cpp b/yapp/popup_history_dlg.cpp index c18ba80..1373526 100644 --- a/yapp/popup_history_dlg.cpp +++ b/yapp/popup_history_dlg.cpp @@ -204,6 +204,7 @@ int CalcCustomControlPos(IEVIEWWINDOW *ieWnd, HWND hMainWindow) RECT rect;
GetWindowRect(GetDlgItem(hMainWindow, IDC_LST_HISTORY), &rect);
ScreenToClient(hMainWindow, &rect);
+ //GetClientRect(hMainWindow, &rect);
ieWnd->x = rect.left + GAP_SIZE;
ieWnd->y = rect.top + GAP_SIZE;
@@ -626,10 +627,10 @@ BOOL CALLBACK DlgProcHistLst(HWND hWnd, UINT msg, WPARAM wParam, LPARAM lParam) RefreshPopupHistory(hWnd, renderer);
bInitializing = 0;
-
+
return TRUE;
- }
-
+ }
+
case WM_DESTROY:
{
UnloadRenderer(hWnd, lstPopupHistory.GetRenderer());
@@ -640,6 +641,7 @@ BOOL CALLBACK DlgProcHistLst(HWND hWnd, UINT msg, WPARAM wParam, LPARAM lParam) case WM_CLOSE:
{
+ //Utils_SaveWindowPosition(hWnd, 0, MODULE, "history_dlg");
DestroyWindow(hWnd);
break;
@@ -647,11 +649,8 @@ BOOL CALLBACK DlgProcHistLst(HWND hWnd, UINT msg, WPARAM wParam, LPARAM lParam) case WM_WINDOWPOSCHANGING:
{
- HDWP hdWnds = BeginDeferWindowPos(4);
- RECT rParent;
WINDOWPOS *wndPos = (WINDOWPOS *) lParam;
- GetWindowRect(hWnd, &rParent);
-
+
if (wndPos->cx < MIN_HISTORY_WIDTH)
{
wndPos->cx = MIN_HISTORY_WIDTH;
@@ -660,16 +659,21 @@ BOOL CALLBACK DlgProcHistLst(HWND hWnd, UINT msg, WPARAM wParam, LPARAM lParam) {
wndPos->cy = MIN_HISTORY_HEIGHT;
}
+
+ RECT rParent;
+ GetWindowRect(hWnd, &rParent);
+ HDWP hdWnds = BeginDeferWindowPos(4);
+
AddAnchorWindowToDeferList(hdWnds, GetDlgItem(hWnd, IDC_CLOSE), &rParent, wndPos, ANCHOR_RIGHT | ANCHOR_BOTTOM);
AddAnchorWindowToDeferList(hdWnds, GetDlgItem(hWnd, IDC_HISTORY_FILTER), &rParent, wndPos, ANCHOR_LEFT | ANCHOR_BOTTOM);
AddAnchorWindowToDeferList(hdWnds, GetDlgItem(hWnd, IDC_HISTORY_FILTER_CASESENSITIVE), &rParent, wndPos, ANCHOR_LEFT | ANCHOR_RIGHT | ANCHOR_BOTTOM);
AddAnchorWindowToDeferList(hdWnds, GetDlgItem(hWnd, IDC_LST_HISTORY), &rParent, wndPos, ANCHOR_ALL);
-
+
EndDeferWindowPos(hdWnds);
MoveCustomControl(hWnd, lstPopupHistory.GetRenderer()); //move the custom control too, if any
-
break;
}
+
case WM_COMMAND:
{
|