From 97589f0ecc7a52677f3c8ed5befdda13e7887be2 Mon Sep 17 00:00:00 2001 From: Basile Burg Date: Wed, 5 Nov 2014 02:13:41 +0100 Subject: [PATCH] fix TMRUFileList invalid files not removed --- src/ce_common.pas | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/src/ce_common.pas b/src/ce_common.pas index adc4d611..1917f99a 100644 --- a/src/ce_common.pas +++ b/src/ce_common.pas @@ -36,6 +36,7 @@ type procedure setMaxCount(aValue: Integer); function checkItem(const S: string): boolean; virtual; procedure Put(Index: Integer; const S: string); override; + procedure InsertItem(Index: Integer; const S: string); override; published property maxCount: Integer read fMaxCount write setMaxCount; public @@ -263,6 +264,13 @@ begin clearOutOfRange; end; +procedure TMRUList.InsertItem(Index: Integer; const S: string); +begin + if not (checkItem(S)) then exit; + inherited; + clearOutOfRange; +end; + procedure TMRUList.Insert(Index: Integer; const S: string); begin if not (checkItem(S)) then exit;