From a0fe63adbc384195f1dd39c749c26e687fff738c Mon Sep 17 00:00:00 2001
From: Robert Scott <code@humanleg.org.uk>
Date: Sat, 11 Nov 2017 21:28:22 +0000
Subject: [PATCH 5/6] TMSCachedTileLoader: add implementation of
hasOutstandingTasks()
---
src/org/openstreetmap/josm/data/imagery/TMSCachedTileLoader.java | 5 +++++
1 file changed, 5 insertions(+)
diff --git a/src/org/openstreetmap/josm/data/imagery/TMSCachedTileLoader.java b/src/org/openstreetmap/josm/data/imagery/TMSCachedTileLoader.java
index 6bf73f8d5..e9b49a288 100644
a
|
b
|
public class TMSCachedTileLoader implements TileLoader, CachedTileLoader {
|
126 | 126 | } |
127 | 127 | } |
128 | 128 | |
| 129 | @Override |
| 130 | public boolean hasOutstandingTasks() { |
| 131 | return this.downloadExecutor.getTaskCount() > this.downloadExecutor.getCompletedTaskCount(); |
| 132 | } |
| 133 | |
129 | 134 | /** |
130 | 135 | * Sets the download executor that will be used to download tiles instead of default one. |
131 | 136 | * You can use {@link #getNewThreadPoolExecutor} to create a new download executor with separate |