From 0d260155eec318a6cff5d10690eee2053cf1a23c Mon Sep 17 00:00:00 2001 From: Eric House Date: Thu, 18 Apr 2013 19:12:49 -0700 Subject: [PATCH] Revert "On some devices a downloaded wordlist shows up twice, once in Internal" This reverts commit 685971532af0d7bfda742be7ebe3c501815cd7e3. No way to test this right now.... --- .../src/org/eehouse/android/xw4/DictUtils.java | 15 ++++----------- 1 file changed, 4 insertions(+), 11 deletions(-) diff --git a/xwords4/android/XWords4/src/org/eehouse/android/xw4/DictUtils.java b/xwords4/android/XWords4/src/org/eehouse/android/xw4/DictUtils.java index 29f2ad759..05a3d8d37 100644 --- a/xwords4/android/XWords4/src/org/eehouse/android/xw4/DictUtils.java +++ b/xwords4/android/XWords4/src/org/eehouse/android/xw4/DictUtils.java @@ -128,13 +128,10 @@ public class DictUtils { // changes? } - private static void tryDir( Context context, HashSet seen, - File dir, boolean strict, + private static void tryDir( Context context, File dir, boolean strict, DictLoc loc, ArrayList al ) { - if ( null != dir && !seen.contains( dir ) ) { - seen.add( dir ); - + if ( null != dir ) { String[] list = dir.list(); if ( null != list ) { for ( String file : list ) { @@ -165,12 +162,8 @@ public class DictUtils { } } - HashSet dirs = new HashSet(); - dirs.add( context.getFilesDir() ); - - tryDir( context, dirs, getSDDir( context ), false, - DictLoc.EXTERNAL, al ); - tryDir( context, dirs, getDownloadDir( context ), true, + tryDir( context, getSDDir( context ), false, DictLoc.EXTERNAL, al ); + tryDir( context, getDownloadDir( context ), true, DictLoc.DOWNLOAD, al ); s_dictListCache =