Rein Klazes : comdlg32: In the file dialog change the position of the file browser when the application changes that of the invisible listbox control .
Alexandre Julliard
julliard at winehq.org
Mon Aug 10 10:35:00 CDT 2009
Module: wine
Branch: master
Commit: 1b740dd14a23b0387c599b65c30b751c7ff1a707
URL: http://source.winehq.org/git/wine.git/?a=commit;h=1b740dd14a23b0387c599b65c30b751c7ff1a707
Author: Rein Klazes <wijn at online.nl>
Date: Sat Aug 8 11:19:42 2009 +0200
comdlg32: In the file dialog change the position of the file browser when the application changes that of the invisible listbox control.
---
dlls/comdlg32/filedlg.c | 14 +++++++++++++-
1 files changed, 13 insertions(+), 1 deletions(-)
diff --git a/dlls/comdlg32/filedlg.c b/dlls/comdlg32/filedlg.c
index de3dc38..4986122 100644
--- a/dlls/comdlg32/filedlg.c
+++ b/dlls/comdlg32/filedlg.c
@@ -1150,7 +1150,7 @@ INT_PTR CALLBACK FileOpenDlgProc95(HWND hwnd, UINT uMsg, WPARAM wParam, LPARAM l
case WM_INITDIALOG:
{
FileOpenDlgInfos * fodInfos = (FileOpenDlgInfos *)lParam;
- RECT rc;
+ RECT rc, rcstc;
int gripx = GetSystemMetrics( SM_CYHSCROLL);
int gripy = GetSystemMetrics( SM_CYVSCROLL);
@@ -1185,6 +1185,18 @@ INT_PTR CALLBACK FileOpenDlgProc95(HWND hwnd, UINT uMsg, WPARAM wParam, LPARAM l
SendCustomDlgNotificationMessage(hwnd,CDN_FOLDERCHANGE);
}
+ /* if the app has changed the position of the invisible listbox,
+ * change that of the listview (browser) as well */
+ GetWindowRect( fodInfos->ShellInfos.hwndView, &rc);
+ GetWindowRect( GetDlgItem( hwnd, IDC_SHELLSTATIC ), &rcstc);
+ if( !EqualRect( &rc, &rcstc))
+ {
+ MapWindowPoints( NULL, hwnd, (LPPOINT) &rcstc, 2);
+ SetWindowPos( fodInfos->ShellInfos.hwndView, NULL,
+ rcstc.left, rcstc.top, rcstc.right - rcstc.left, rcstc.bottom - rcstc.top,
+ SWP_NOACTIVATE | SWP_NOZORDER);
+ }
+
if (fodInfos->ofnInfos->Flags & OFN_ENABLESIZING)
{
GetWindowRect( hwnd, &rc);
More information about the wine-cvs
mailing list