[Mac] Reset Touch Bar Text Suggestions on Main Thread

Previously, -requestSuggestions would asynchronously reset
|suggestions_| on a thread separate from the main thread. This caused
issues were -createCandidateListItem could try to read |suggestions_|
while it was being reset, causing zombie dealloc crashes.

Now, -requestSuggestions resets |suggestions_| on the main thread, so
the previous crashes cannot happen.

Bug: 717553
Change-Id: I016b054673fe8d2bb9bcb6c644c90b3c83eef311
Reviewed-on: https://chromium-review.googlesource.com/1175223
Reviewed-by: Avi Drissman <avi@chromium.org>
Reviewed-by: Sarah Chan <spqchan@chromium.org>
Commit-Queue: Tessa Nijssen <tnijssen@google.com>
Cr-Commit-Position: refs/heads/master@{#583786}
1 file changed