Views shouldn't be recycled if the view id is changed as the identity
of the view is then altered.
Second pass: this has been further tested by adding/removing AppWidgets
on a test phone.
Bug: 181985606
Test: atest CtsWidgetTestCases:RemoteViewsTest
Test: atest CtsWidgetTestCases:RemoteViewsRecyclingTest
Test: atest CtsInputMethodTestCases:android.view.inputmethod.cts.InputConnectionBlockingMethodTest
Change-Id: I8924c02f7f0223458f556a07a3dfdc96b4ce612e
Added dampening logic to caluclate the distance to
overscroll.
Updated StretchEffect to support independent
maximum stretch amounts for the x/y axis
Removed debugging parameters to configure
stretch distance since they are no longer
used. Removed hidden API calls to configure
stretch distance in ScrollView/HorizontalScrollView
Bug: 179047472
Test: re-ran EdgeEffectTests
Change-Id: I4698669273d364695a21c2cce00ec2cfec41b2cc
This reverts commit 308a272289.
Bug: 183104573
Test: Install from Play Store with the screen off on wembley, and the device doesn't crash when the screen turns back on.
Change-Id: I289fcafc6685c4ede295e8d6916a54da9bac1ad5
This reverts commit 54deae4c69.
Bug: 183104573
Test: Install from Play Store with the screen off on wembley, and the device doesn't crash when the screen turns back on.
Change-Id: I36d4736af5853ab99e2d2024de8679ac8991bd58
We want to test the stretch EdgeEffect for all apps, not
just those that target S and higher.
Bug: 182191316
Test: None.
Change-Id: I29a46a5c9ac6bc64f0abfa8dbd4605ed7d75ea62
Fixes: 182186617
refreshChildren() could be called with an adapter with no
elements, which would call mAdapter.getView(0), where there
is no element at the 0th index.
Test: ran CollectionAppWidgetTest, manual test of example
Change-Id: Ia90cb823c0bd40c46ace1767a885545028975bb9
Views shouldn't be recycled if the view id is changed as the identity
of the view is then altered.
Bug: 181985606
Test: atest CtsWidgetTestCases:RemoteViewsTest
Test: atest CtsWidgetTestCases:RemoteViewsRecyclingTest
Change-Id: I68415087297312eb2c1985d272be2ac535507c2a
Fixes: 182499389
With the glow edge effect, using the drag gesture to reduce
the edge glow could cause the glow to flip and repeat. This
was caused by the update() modifying the determined distance
during the pull when it wasn't animating.
We also force the alpha to be 0 if the pull distance is 0.
Test: manual testing
Change-Id: Iacc1df0fcb92e3380523187badf7ea62d7d19d2f
Updated stretch constant from 0.1f to 1f
Updated distance to be maximum of width/height
Bug: 182567334
Test: Re-ran CTS tests
Change-Id: I943c7d1013cfabd86bb678fa7b408f0f97a17075
SpellCheckerSessionListener callback methods will be called on
the provided executor.
This CL also adds more description for 'bundle' parameter.
Bug: 179804789
Test: atest CtsInputMethodTestCases:SpellCheckerTest
Change-Id: I43f9f04fc335ad45d2580f4711b19aee214bc7dd
Bug: 182467111
Test: Sample app trying out different combinations of views and event
listeners
Test: atest RemoteViewsFixedCollectionAdapterTest
Change-Id: Ia3fc0af0499cbfaa85e9eb1bf2a24f1e404f17a3
If InputMethodService declares suppressesSpellChecker="true", the system
SpellCheckerService will be disabled.
With TextView, when IMSs are switched while the user is editing,
SuggestionSpans that were previously added will not be removed even if
the next IMS declares suppressesSpellChecker="true".
This is because we don't know if the SuggestionSpans were from Spell
Checker, App, or IMS.
Bug: 153473490
Test: atest CtsInputMethodTestCases:SpellCheckerTest
Change-Id: Ia22b8758111087818beea8c07b1c173f1a94b8e4
Fixed issue where mDistance and mVelocity fields
would be infinite/NaN in situations where onAbsorb
is called before setSize leading to division by zero
issues.
Updated constants to be less significant
stretch
Fixes: 182567334
Test: Updated EdgeEffectTests
Change-Id: I4007b03271c6b5e79e95d5fe6c7c44e8c0869cd1
Previously, Editor.onDrop used a try/finally block to request and
release URI permissions. This doesn't work for the case when an app
sets an OnReceiveContentListener (or subclasses TextView and overrides
the onReceiveContent() method). If using a background thread to
process the content in the custom impl for receiving content,
permissions will be revoked in the finally block before the app has
had a chance to process the URI.
With this change, when Editor requests permissions, they will be bound
to the app process and released automatically when the app process
terminates.
Bug: 181178998
Test: atest CtsWindowManagerDeviceTestCases:CrossAppDragAndDropTests
Test: Manually verified using development/samples/ReceiveContentDemo
Change-Id: I7ae38069fb741925211b42c7ff28784eb9722ce3
Introduces SentenceIterator into android.widget.SpellChecker and
uses it to detect the start/end of spell check range instead of
using a fixed length.
Fix: 179125303
Fix: 179124679
Test: atest CtsInputMethodTestCases:SpellCheckerTest
Change-Id: If6dd044e24dcaa58381949c221a5f9af57a4104f
We receive translation doesn't work issues but we don't have enough
log information to help debugging the issue. To help clarify issue
- Add more information when dumpsys activity information
- We use Log.isLoggable() to control if the debug log need to be
printed. But for the development phase, we enable print log on the
debuggable ROM, we will delete it before platform release.
Bug: 181975692
Test: manual. adb shell dumpsys activity <myactivity> --translation
(Can find dumpsys result of sample app in bug 182433547)
Change-Id: I4a9a1667a544fc4d1654c5f297d365a8288b1f4a
Bug: 171228096
Use the spring animation from the prototype in
EdgeEffect.
Test: manual testing for fling and recede
Change-Id: I7eec03a98f5d26153512ba402d6bb5bc5dc70ffb
There's no action the developer should take based on this possibility,
so there's no need to have it in the javadoc for the method.
Bug: 181551575
Test: None, change only touches javadoc
Change-Id: I571bb8c28a3831d8541e1713b0048127c3dc24a2
Bug: 171228096
Added two ChangeIds for stretch overscroll:
USE_STRETCH_EDGE_EFFECT_BY_DEFAULT makes stretch overscroll
the default.
USE_STRETCH_EDGE_EFFECT_FOR_SUPPORTED makes stretch overscroll
the default for applications that use the new EdgeEffect
constructor that accepts an AttributeSet. This indicates
knowledge of stretch overscroll APIs and can be a proxy for
supporting stretch overscroll.
Test: Both flags on apps that support and don't support new api
Change-Id: If2ec832c9656116fe1aa64d33682c489abbde30f