From 6052f527c236c75f29966fbe8baac8e2c1d85842 Mon Sep 17 00:00:00 2001 From: Reinhard Pointner Date: Mon, 4 Jan 2010 11:06:56 +0000 Subject: [PATCH] * fixed bug that involved cells not updating (visually) --- .../ui/panel/subtitle/VideoHashSubtitleDownloadDialog.java | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/source/net/sourceforge/filebot/ui/panel/subtitle/VideoHashSubtitleDownloadDialog.java b/source/net/sourceforge/filebot/ui/panel/subtitle/VideoHashSubtitleDownloadDialog.java index 44a84d87..3721f165 100644 --- a/source/net/sourceforge/filebot/ui/panel/subtitle/VideoHashSubtitleDownloadDialog.java +++ b/source/net/sourceforge/filebot/ui/panel/subtitle/VideoHashSubtitleDownloadDialog.java @@ -223,6 +223,11 @@ class VideoHashSubtitleDownloadDialog extends JDialog { @Override public void actionPerformed(ActionEvent evt) { + // disable any active cell editor + if (subtitleMappingTable.getCellEditor() != null) { + subtitleMappingTable.getCellEditor().cancelCellEditing(); + } + // don't allow restart of download as long as there are still unfinished download tasks if (downloadService != null && !downloadService.isTerminated()) { return; @@ -269,7 +274,7 @@ class VideoHashSubtitleDownloadDialog extends JDialog { // start download if (downloadQueue.size() > 0) { - downloadService = Executors.newSingleThreadExecutor(); + downloadService = Executors.newFixedThreadPool(2); for (DownloadTask downloadTask : downloadQueue) { downloadTask.getSubtitleBean().setState(StateValue.PENDING);