mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-08-31 10:20:40 +02:00
LCL-Win32: Show also empty ListView subitem as selected with RowSelect and OwnerData. Issue #38848, patch by Zaher Dirkey.
git-svn-id: trunk@65092 -
This commit is contained in:
parent
2f5e5ca72a
commit
66493736c2
@ -115,23 +115,18 @@ var
|
|||||||
else
|
else
|
||||||
txt := '';
|
txt := '';
|
||||||
end;
|
end;
|
||||||
if txt <> '' then
|
if DataInfo^.hdr.code = UInt(LVN_GETDISPINFOA) then
|
||||||
begin
|
begin
|
||||||
if DataInfo^.hdr.code = UInt(LVN_GETDISPINFOA) then
|
LVInfo^.DispInfoTextA[LVInfo^.DispInfoIndex]:=Utf8ToAnsi(txt+#0);
|
||||||
begin
|
DataInfo^.item.pszText := @(LVInfo^.DispInfoTextA[LVInfo^.DispInfoIndex][1]);
|
||||||
LVInfo^.DispInfoTextA[LVInfo^.DispInfoIndex]:=Utf8ToAnsi(txt);
|
|
||||||
DataInfo^.item.pszText := @(LVInfo^.DispInfoTextA[LVInfo^.DispInfoIndex][1]);
|
|
||||||
end
|
|
||||||
else
|
|
||||||
begin
|
|
||||||
LVInfo^.DispInfoTextW[LVInfo^.DispInfoIndex]:=UTF8Decode(txt);
|
|
||||||
DataInfo^.item.pszText := @(LVInfo^.DispInfoTextW[LVInfo^.DispInfoIndex][1]);
|
|
||||||
end;
|
|
||||||
inc(LVInfo^.DispInfoIndex);
|
|
||||||
if LVInfo^.DispInfoIndex=LV_DISP_INFO_COUNT then LVInfo^.DispInfoIndex:=0;
|
|
||||||
end
|
end
|
||||||
else
|
else
|
||||||
DataInfo^.item.pszText := nil;
|
begin
|
||||||
|
LVInfo^.DispInfoTextW[LVInfo^.DispInfoIndex]:=UTF8Decode(txt+#0);
|
||||||
|
DataInfo^.item.pszText := PChar(LVInfo^.DispInfoTextW[LVInfo^.DispInfoIndex]);
|
||||||
|
end;
|
||||||
|
inc(LVInfo^.DispInfoIndex);
|
||||||
|
if LVInfo^.DispInfoIndex=LV_DISP_INFO_COUNT then LVInfo^.DispInfoIndex:=0;
|
||||||
end;
|
end;
|
||||||
if (DataInfo^.item.mask and LVIF_IMAGE) <> 0 then
|
if (DataInfo^.item.mask and LVIF_IMAGE) <> 0 then
|
||||||
begin
|
begin
|
||||||
|
Loading…
Reference in New Issue
Block a user