mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-09-04 18:40:29 +02:00
win32: fix win32dialogs compilation with recent fpc 2.5.1 on win64 platform (based on patch of Cyrax, issue #0019163)
git-svn-id: trunk@30301 -
This commit is contained in:
parent
2eac29c467
commit
d9dfb7ca86
@ -154,7 +154,7 @@ type
|
||||
{$endif}
|
||||
|
||||
function OpenFileDialogCallBack(Wnd: HWND; uMsg: UINT; wParam: WPARAM;
|
||||
lParam: LPARAM): UINT; stdcall;
|
||||
lParam: LPARAM): UINT_PTR; stdcall;
|
||||
|
||||
function SaveApplicationState: TApplicationState;
|
||||
procedure RestoreApplicationState(AState: TApplicationState);
|
||||
@ -480,7 +480,7 @@ end;
|
||||
}
|
||||
|
||||
function OpenFileDialogCallBack(Wnd: HWND; uMsg: UINT; wParam: WPARAM;
|
||||
lParam: LPARAM): UINT; stdcall;
|
||||
lParam: LPARAM): UINT_PTR; stdcall;
|
||||
var
|
||||
OpenFileNotify: LPOFNOTIFY;
|
||||
OpenFileName: Windows.POPENFILENAME;
|
||||
@ -701,7 +701,7 @@ begin
|
||||
{$endif}
|
||||
|
||||
nMaxFile := FileNameBufferLen + 1; // Size in TCHARs
|
||||
lpfnHook := @OpenFileDialogCallBack;
|
||||
lpfnHook := LPOFNHOOKPROC(@OpenFileDialogCallBack);
|
||||
Flags := GetFlagsFromOptions(AOpenDialog.Options);
|
||||
New(DialogRec);
|
||||
// new initializes the filename fields, because ansistring and widestring
|
||||
|
@ -99,7 +99,7 @@ implementation
|
||||
{$R *.res}
|
||||
|
||||
function OpenPictureDialogCallBack(hWnd: Handle; uMsg: UINT; wParam: WPARAM;
|
||||
lParam: LPARAM): UINT; stdcall;
|
||||
lParam: LPARAM): UINT_PTR; stdcall;
|
||||
var
|
||||
OpenFileName: Windows.POPENFILENAME;
|
||||
DialogRec: POpenFileDialogRec;
|
||||
@ -162,7 +162,7 @@ begin
|
||||
Move(PChar(AnsiString(ResName))^, lpTemplateName^, Length(ResName));
|
||||
end;
|
||||
Flags := Flags or OFN_ENABLETEMPLATE;
|
||||
lpfnHook := @OpenPictureDialogCallBack;
|
||||
lpfnHook := LPOFNHOOKPROC(@OpenPictureDialogCallBack);
|
||||
end;
|
||||
end;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user