mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-08-07 20:56:31 +02:00
LCL Win32: take care of more clipboard formats. Issue #20089, patch from Flávio Etrusco
git-svn-id: trunk@32726 -
This commit is contained in:
parent
1acfc93cd4
commit
ae0edb7828
@ -328,11 +328,15 @@ begin
|
||||
Result := 'audio/riff';
|
||||
CF_SYLK:
|
||||
Result := 'application/x-ms-shortcut';
|
||||
CF_LOCALE:
|
||||
Result := 'application/x-ms-locale';
|
||||
CF_OEMTEXT:
|
||||
Result := 'application/x-ms-oemtext';
|
||||
else
|
||||
SetLength(Result,1000);
|
||||
FormatLength:= Windows.GetClipboardFormatName(FormatID, PChar(Result), 1000);
|
||||
if FormatLength = 0 then
|
||||
raise Exception.Create('Unknown clipboard format');
|
||||
raise Exception.CreateFmt('Unknown clipboard format: %d', [FormatID]);
|
||||
SetLength(Result,FormatLength);
|
||||
{$IFDEF VerboseWin32Clipbrd}
|
||||
debugln('TWin32WidgetSet.ClipboardFormatToMimeType FormatID=',dbgs(FormatID),' ',Result);
|
||||
|
Loading…
Reference in New Issue
Block a user