Remove the usage of BrowserThread::FILE in the spellchecker files

Previously landed as
https://chromium-review.googlesource.com/c/chromium/src/+/619607

Relanding with RunAllBlockingPoolTasksUntilIdle() in browser test.

The usage of BrowserThread::FILE is deprecated in favor of the
post_task.h API.

This is a new attempt at
https://chromium-review.googlesource.com/c/510018,
that got reverted because of flaky tests.

I changed the code to make sure the dictionary is deleted on the
same task runner is it used in.

TBR=rouslan@chromium.org

Bug: 689520
Change-Id: Ib0b0d39dbdd0f0f7625baab65fcfe3e0a28306e0
Reviewed-on: https://chromium-review.googlesource.com/667239
Reviewed-by: Francois Doray <fdoray@chromium.org>
Reviewed-by: Gabriel Charette <gab@chromium.org>
Commit-Queue: Francois Doray <fdoray@chromium.org>
Cr-Commit-Position: refs/heads/master@{#501955}
5 files changed