"Fix" search

- Only consider a locale actually indexed after it has had a full
   update run
 - Run all indexing queueing on the AsyncTask's serial threadpool
   to avoid more threading issues.

Change-Id: I8fc84b0faafc5c104d090b6bbd87857550b3af89
Fixes: 27826745
This commit is contained in:
Jason Monk
2016-04-14 14:34:16 -04:00
parent d49a846a39
commit 6c9e884aa0
2 changed files with 60 additions and 55 deletions

View File

@@ -564,12 +564,7 @@ public class SettingsActivity extends SettingsDrawerActivity
// Run the Index update only if we have some space
if (!Utils.isLowStorage(this)) {
long indexStartTime = System.currentTimeMillis();
AsyncTask.execute(new Runnable() {
@Override
public void run() {
Index.getInstance(getApplicationContext()).update();
}
});
Index.getInstance(getApplicationContext()).update();
if (DEBUG_TIMING) Log.d(LOG_TAG, "Index.update() took "
+ (System.currentTimeMillis() - indexStartTime) + " ms");
} else {