mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-04-05 07:53:18 +02:00
Win32: Fix crash in TWin32WSOpenDialog.DestroyHandle, caused by me in commit 7cfdbd74
.
This commit is contained in:
parent
441180f7e0
commit
126f2628d4
@ -1073,6 +1073,7 @@ var
|
|||||||
Dialog: IFileDialog;
|
Dialog: IFileDialog;
|
||||||
Idx: Integer;
|
Idx: Integer;
|
||||||
begin
|
begin
|
||||||
|
Idx := -1;
|
||||||
if (ACommonDialog.Handle <> 0) and (ACommonDialog.Handle <> INVALID_HANDLE_VALUE) then
|
if (ACommonDialog.Handle <> 0) and (ACommonDialog.Handle <> INVALID_HANDLE_VALUE) then
|
||||||
begin
|
begin
|
||||||
if CanUseVistaDialogs(TOpenDialog(ACommonDialog)) and not IsXPStyleFallBack(TOpenDialog(ACommonDialog), Idx) then
|
if CanUseVistaDialogs(TOpenDialog(ACommonDialog)) and not IsXPStyleFallBack(TOpenDialog(ACommonDialog), Idx) then
|
||||||
|
Loading…
Reference in New Issue
Block a user