summaryrefslogtreecommitdiff
path: root/core/java/android/transition/TextChange.java
Commit message (Collapse)AuthorAgeFilesLines
* Make fading transitions work betterChet Haase2013-09-261-286/+0
| | | | | | | | | | | | | | | | | | | | | | | | | Previously, a Fade transition would only affect a view if its parent hierarchy was not also affected between the start/end states. This caused problems for views which were removed from their parents between scenes when their parents' visibility also changed between those scenes. The effect would be that the transition would fade the parent... but the child would no longer be in that parent, so the user would just see the child view blink out. This fix ensure that views are faded appropriately by fading them regardless the parent hierarchy; if a view is removed from its parent, fade it out. Additionally, if that view has not been removed from its parent, but its parent is no longer parented *and* scene being transitioned from is based on a layout resource file (and thus the views are considered temporary after transitioning), then it is removed from its parent to be faded out in the overlay. Also, renamed TextChange to ChangeText to be more consistent with other transition class names. Change-Id: I4e0e7dfc9e9d95c7a4ca586534b6d204c4f3bae0
* Disable ActionBar usage of transitionsChet Haase2013-09-231-1/+49
| | | | | | | | | | | | | | | | | | Various artifacts across apps were coming from ActionBar's use of the new transitions framework. Disabling transitions for now to get things back to a more stable state. Also, fixed some related bugs in transitions themselves, including a change in TextChange to account for text selection, which was causing errors in Keep's SearchView. Issue #10860557 TextChange animator may old stale value Issue #10819685 sometimes icons are lighter Issue #10750525 Share and Settings icons overlap when stopping slideshow Issue #10839551 Sometimes the search text box is right-aligned in Keep Issue #10727484 Cursor incorrectly positioned after entering first letter during search action in keep app Change-Id: Iad7cbf3297e18018308b8148b3519b032e63dace
* Add equals() and hashcode() to SpannableStringChet Haase2013-09-191-0/+7
| | | | | | | | | | | | | | | ActionBar uses a transition to animate text changes. This transition depends on testing the equality of start/end text values in CharSequence objects. Without equals(), SpannableString will return false for objects whose references are different, but whose text is exactly the same. This CL adds the equals() method, and the accompanying hashcode method, to ensure that two Spanned implementations will always be equal if their text and span data are equal. Issue #10760075 Wrong unread count in actionbar Change-Id: I5e77d40dd302eca035e8c56d40f3cd0aef8e6424
* Fix TechChange's assumption about TextView targetsChet Haase2013-09-121-3/+6
| | | | | | | | | | | Some of the code in the TextChange transition assumed that the start values for a transition were for a TextView object. This may not be the case, and we should return early (without creating an animator) when it is not. Issue #10725388 Frequent Framework crashes across apps Change-Id: I6999eb2288f107f4b93ddb5b77cd068069d831ed
* TextChange transition now uses CharSequence instead of StringChet Haase2013-09-061-2/+2
| | | | | | | | | | | | | | TextChange made a bad assumption that target text views contained String objects as their text, which is not always the case. For example, Gmail ActionBar text views may contain SpannableString objects, which caused a crash due to a bad cast operation. Fix is to simply use CharSequence instead of String as the value that is being stored and set on the text view. Issue #10651858 TextChange transition casts CharSequence to String when not necessarily safe Change-Id: I3f67f5d5e39201dc0fd2edcd3e4243033cf9ae08
* Transition API changes from API council recommendationsChet Haase2013-09-041-0/+228
Issue #10460684 KLP API Review: android.view.transition and android.animation Issue #10570740 Transitions: inflate transition targets from xml Change-Id: I7a3f6d3aece2fcafc5efd555d033f79e86635c98