Revert r51062 #51c28613b2 "LCL-Win32: Fix drag and drop issue of ListView items with ImageList." Caused regression.

git-svn-id: trunk@51504 -
This commit is contained in:
juha 2016-02-05 21:30:42 +00:00
parent 61f389ffdb
commit 9522f5c460

View File

@ -688,14 +688,7 @@ begin
_gnu_lvi.iSubItem := ASubIndex; _gnu_lvi.iSubItem := ASubIndex;
_gnu_lvi.pszText := PChar(PWideChar(UTF8ToUTF16(AText))); _gnu_lvi.pszText := PChar(PWideChar(UTF8ToUTF16(AText)));
if (TListView(ALV).ViewStyle in [vsList, vsReport]) and Assigned(TListView(ALV).SmallImages) then SendMessage(ALV.Handle, LVM_SETITEMTEXTW, WPARAM(AIndex), LPARAM(@_gnu_lvi));
begin
_gnu_lvi.Mask := LVIF_TEXT or LVIF_IMAGE;
_gnu_lvi.iItem := AIndex;
_gnu_lvi.iImage := AItem.ImageIndex;
SendMessage(ALV.Handle, LVM_SETITEMW{TEXTW}, WPARAM(AIndex), LPARAM(@_gnu_lvi));
end else
SendMessage(ALV.Handle, LVM_SETITEMTEXTW, WPARAM(AIndex), LPARAM(@_gnu_lvi));
// autosize is an *extreme* performance bottleneck, even if WM_SETREDRAW // autosize is an *extreme* performance bottleneck, even if WM_SETREDRAW
// was set to false it will ignore this and still redraw all columns. // was set to false it will ignore this and still redraw all columns.
// We will therefore postpone all autosizing until EndUpdate where we do // We will therefore postpone all autosizing until EndUpdate where we do