diff options
author | Yorke Lee <yorkelee@google.com> | 2014-01-16 11:26:46 -0800 |
---|---|---|
committer | Jay Shrauner <shrauner@google.com> | 2014-03-04 20:33:15 +0000 |
commit | d5b5d0a35d0f0e7dfd75828976dc3c0f95cdd672 (patch) | |
tree | dff9410a777a5b2305cb51fe45517b9f077d1479 /tests | |
parent | 1a31e3439a23cb2c0ff4658e0bef2d3782825e72 (diff) |
Add drag to remove for favorites in Dialer
* Add remove view in dialtacts_activity.xml, and rearrange layout slightly
so that it takes up the same position in the layout as the search view
container. Contacts that are dragged to this remove view will be unstarred
and unpinned.
* Add drag event logic to the Remove View, so that when the user hovers a
contact over it, the UI will continue to respond. Previously, only the
PhoneFavoritesListView would detect touch events.
* Refactor DragDropController and OnDragDropListener into separate classes.
DragDropController performs the work of receiving drag/drop events from
multiple views, combining them, and then firing off callbacks as appropriate
to OnDragDropListeners. Each OnDragDropListener can then update their UI
or internal data model as necessary in response to the callbacks.
OnDragDropListener <----------------------------------------
^ |
| |
DialtactsActivity ---------------> RemoveView |
| | |
v | | callbacks
PhoneFavoriteListFragment |drag events |
| | |
v v |
PhoneFavoriteListView ------------> DragController--------
drag events |
| callbacks
v
PhoneFavoritesTileAdapter --> OnDragDropListener
* While in here, add a content description for the clear search button
Bug: 13083459
Change-Id: I044ad1c5aa42c7686bde6bf5074095a4fe879bde
(cherry picked from commit 3cefcc69c10ab12bd782a0b53779dbd1cc0e2aa1)
Diffstat (limited to 'tests')
0 files changed, 0 insertions, 0 deletions