mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-08-29 08:50:16 +02:00
sysenvapis_win: don't use 'open' verb for shellexecute in OpenDocument. Use nil instead. This will perform the default action. Resolves issue #22374.
git-svn-id: trunk@38958 -
This commit is contained in:
parent
fd7d0baca4
commit
6a491651ad
@ -24,12 +24,12 @@ begin
|
||||
if Win32Platform = VER_PLATFORM_WIN32_NT then
|
||||
begin
|
||||
ws := UTF8Decode(AURL);
|
||||
Result := ShellExecuteW(0, 'open', PWideChar(ws), nil, nil, SW_SHOWNORMAL) > 32;
|
||||
Result := ShellExecuteW(0, nil, PWideChar(ws), nil, nil, SW_SHOWNORMAL) > 32;
|
||||
end
|
||||
else
|
||||
begin
|
||||
ans := Utf8ToAnsi(AURL); // utf8 must be converted to Windows Ansi-codepage
|
||||
Result := ShellExecute(0, 'open', PAnsiChar(ans), nil, nil, SW_SHOWNORMAL) > 32;
|
||||
Result := ShellExecute(0, nil, PAnsiChar(ans), nil, nil, SW_SHOWNORMAL) > 32;
|
||||
end;
|
||||
{$ENDIF}
|
||||
end;
|
||||
|
Loading…
Reference in New Issue
Block a user