From 30993cb6ad319bff496c5fbc3362308f8592f29e Mon Sep 17 00:00:00 2001 From: 0x90d <46010672+0x90d@users.noreply.github.com> Date: Wed, 3 Apr 2019 20:41:03 +0200 Subject: [PATCH] Fixes getting more than first thumbnail, fix #38 --- DuplicateFinderEngine/ScanEngine.cs | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/DuplicateFinderEngine/ScanEngine.cs b/DuplicateFinderEngine/ScanEngine.cs index 0432d0d2..af4e8436 100644 --- a/DuplicateFinderEngine/ScanEngine.cs +++ b/DuplicateFinderEngine/ScanEngine.cs @@ -40,8 +40,10 @@ public async void StartSearch() { positionList.Clear(); ElapsedTimer.Reset(); SearchSW.Reset(); + float positionCounter = 0f; for (var i = 0; i < Settings.ThumbnailCount; i++) { - positionList.Add(1.0F / (Settings.ThumbnailCount + 1)); + positionCounter += 1.0F / (Settings.ThumbnailCount + 1); + positionList.Add(positionCounter); } _isScanning = true; m_pauseTokeSource = new PauseTokenSource();