NPE when iterating by character and word in Launcher widgets.

1. The character and word iterators were use the application
   context to keep track of locale changes. However, for widgets
   the context from which the app context is obtained is custom
   created therefore the app context is null and the iterators
   code does not expect that. Now we are caching the locale
   and update it when the configuration changes.

bug:6642281

Change-Id: I3fd201ab9e4efd79e3bdc8afd8ee644e4354a7fb
2 files changed