diff --git a/lcl/comctrls.pp b/lcl/comctrls.pp index b4728d2659..b4fc94bccd 100644 --- a/lcl/comctrls.pp +++ b/lcl/comctrls.pp @@ -889,6 +889,7 @@ type constructor Create(AOwner: TComponent); override; destructor Destroy; override; procedure BeginUpdate; + procedure Clear; procedure EndUpdate; function FindCaption(StartIndex: Integer; Value: string; Partial, Inclusive, Wrap: Boolean; PartStart: Boolean = True): TListItem; property BoundingRect: TRect read GetBoundingRect; diff --git a/lcl/include/customlistview.inc b/lcl/include/customlistview.inc index c1c045d1ca..54bd0d1ce5 100644 --- a/lcl/include/customlistview.inc +++ b/lcl/include/customlistview.inc @@ -392,6 +392,11 @@ begin then TWSCustomListViewClass(WidgetSetClass).BeginUpdate(Self); end; +procedure TCustomListView.Clear; +begin + FListItems.Clear; +end; + {------------------------------------------------------------------------------} { TCustomListView EndUpdate } {------------------------------------------------------------------------------}