Fix rotation crash.

On orientation changed or activity paused/ restarted, the window
and context were not being properly refreshed for this widget.
This led to crashes when the user tried to show the alternates popup.
The reason the context/ window were not being refreshed
is that references were being held by the chips to one or both of these.
The chips were also retaining references to the spannable, which caused
issues in that the spannable was not being updated in the chips, and
after a rotation, the chip would no longer be able to find where
it had been attached to the spannable. To fix all these issus,
I made the RecipientChip class a seperate, simple data holding
class and allowed the RecipientEditTExtview to do the heavy lifting
as it contains the correct contextual information. This has
solved the crashes I had been seeing.
Change-Id: I4123f7bb2a5195c084efa602c5409d87596275d7
2 files changed
tree: b06d09ce6ad8913614b02359697f4c6af6d3ac3c
  1. res/
  2. src/
  3. Android.mk
  4. list_selector_pressed_holo_dark.9.png