Overscroll updates:
Same shape, but smaller radius (doesn't come as far into the view)
and more translucent (max 15% instead of 50%). Overall, more subtle.
Toast updates:
Light background, smaller, dark font, closer to the bottom of the
container.
Test: manual unit tests. Also:
cts test ToastTest for toast changes
cts test EdgeEffectTests for EdgeEffect changes (adding some tests to
known-failures for now, due to brittle golden-image failures - see
CL ag/2596621)
Bug: 30563264 Refresh toast visuals for Android ODR
Bug: 63010438 Tweaks to overscroll animation
Change-Id: I0fac6322b0b81d030c8d174852c134211290bbea
Bitmap sizes could be arbitrary large when they were sent
over to the system. We're now reducing them to reasonable
sizes.s
Also fixed that notification bitmaps were not put into
ashmem anymore since it got lost in a refactor.
Test: code inspection
Bug: 62319200
Merged-In: I87db7656e749666b9eab1f67fd497f155c407e18
Change-Id: I87db7656e749666b9eab1f67fd497f155c407e18
Previously, TextInputTimePickerView used the default numeric IME, which
could result in cases where the digits displayed in the text fields were
native, but the IME showed ASCII digits resulting in a mix.
Now we use setImeHintLocales to hint that we need a localized IME.
Change-Id: Ic4041dcc65a31bd00741c6d96d8cbc5dac9d77c8
Fixes: 63650251
Test: Manual (tested under en-US and ar-BH locales)
The index on where to add a child view was not being saved when writing
to a Parcel. This causes the index to default to 0 and resulted in views
always being added as the first view.
Now, persist this value to the Parcel and restore it.
Test: booted up on Nexus 6P, created notification with RemoteView, added
two views and verified views added in correct order.
Bug: 63177271
Change-Id: I94384e348b8a5168efe0601f382cdd2db6791fdb
Test: bit CtsViewTestCases:android.view.textclassifier.cts.TextClassificationManagerTest
bit FrameworksCoreTests:android.widget.TextViewActivityTest
bit FrameworksCoreTests:android.widget.TextViewActivityMoutseTest
Bug: 62745625
Change-Id: I360250a5c2a92d09c8d8f559b51c74f490f70c2c
Since CONTEXT_RESTRICTED is not a default flag of createPackageContext,
we can't rely on it for preventing unexpected font injections.
To protect developers and existing apps from a risk of font injection,
stop loading font from other package's resouce unless the developer
explicitly set CONTEXT_IGNORE_SECURITY.
Bug: 62813533
Bug: 62879353
Test: Manually done
Merged-In: I4442ddc48dadb5c968b444be86038b602074d301
Change-Id: I4442ddc48dadb5c968b444be86038b602074d301
(cherry picked from commit 6d6cd68660)
While a negative height is pretty silly, crashing apps on
the new version of android makes them sad.
Test: Existing CTS passes.
Bug: 62434804
Change-Id: I5fc3fc50fb6ccfa9e96f38ded4fb8e338f263f09
This CL will be reverted once it merges into the next release branch
to re-introduce the proposed APIs.
This CL also makes the following code changes to preserve API
compatibility:
-- It keeps the recently added RemoteViews.clone() synchronized logic
intact, but moves it inside the method to avoid changing the API
signature.
-- It reverts the RttCall.read() behavior to the oc-dev logic, since
we can't throw IOException until we get an API level bump. (The
original logic returned null instead of throwing.)
Test: builds, boots
Bug: 62427252, 62431886, 62427329
Bug: 62468911, 62431162, 62428935, 62429096
Bug: 37290820, 37359238, 36886243
Bug: 30143923, 35761231, 62192626, 29829689
Change-Id: I83d723f598cb0ee1fe198e65debd86ef7fd0420c
Test: bit CtsWidgetTestCases:android.widget.cts.TextViewTest
bit CtsWidgetTestCases:android.widget.cts.EditTextTest
Bug: 62271937
Change-Id: Ib3447281f3bd1abc811a25fc55ad55e34e155bbb
Because cloning wasn't synchronized, the notification
could become a non-root temporarily which in turn could
lead to a crash.
1. We're now properly synchronizing the cloning, such that
this can't happen anymore
2. We're now only cloning the old statusbar notification lightly
instead of heavily to avoid this altogether
Test: manual, update decoratedcustomview notifications really fast
Change-Id: Ia6525eec64ad9a26956ca2198e20198f55b2173c
Fixes: 62181033
Remove throwing an error and instead clamp
the selected date to min/max when changing
ranges.
Bug: 36636681
Test: manually verified that the case in the
bug does not happen again
Change-Id: If540f58d21375d2320df5215504d4569e5c2be2e
* splits the auto-size setup part from the execution
function:
** in TextView CTOR we only setup and we leave the
actual auto-sizing execution to happen in the
view||text layout phase
** encapsulated the conditions needed to start
applying auto-size in the execution function
* introduces a private way to set the text size
without requesting a new layout pass; auto-size
always uses this practically setting the text
size on the paint object and creating a new
layout
* calls execution autoSizeText() from within
TextView#checkForRelayout() if not requestLayout()
is needed => this makes sure that auto-size will be
performed even if a view layout is not requested,
but only a text layout
* fixes the calculation of the sizes available for
auto-size when configured via granularity
Bug: 62050646
Bug: 38409622
Bug: 38440435
Bug: 62109627
Test: run cts --test android.widget.cts.TextViewTest -m \
CtsWidgetTestCases
Test: manually tested the new behaviors in demo apps
Test: new test attached in topic
Change-Id: I4ccaa0a0afa3b5aa47213442d0029da2c74e7eb4
Added a new dimension for the bottom margin after the notification
content if there is a progress bar. This value is needed to create a
larger space for the progress bar. If it is adjusted to be larger, than
the progress bar will appear to be further away from the notification
content.
Also add dimensions for the progress bar size. This value needs to also
override the max and min heights otherwise the max/min heights would
differ from the layout_height.
Test: booted on phone and Android Auto headunit
Bug: 33210494
Change-Id: I20011b3f79a0d3f81c6317e715d8d2310c5cd87b
This commit specially checks isDefaultFocusHighlightNeeded for
ImageView. We should also check with the content drawable of the
ImageView besides its foreground or background.
Bug: 62141891
Test: cts-tradefed run singleCommand cts --skip-device-info
--skip-preconditions --abi armeabi-v7a -m CtsViewTestCases -t
android.view.cts.View_DefaultFocusHighlightTest#testIsDefaultFocusHighlightNeeded
Change-Id: Iaf12a5863d7760d9361d0196a46de07a9ccda74e
This CL early returns from auto sizing text if the view is not measured
yet.
Test: run cts --test android.widget.cts.TextViewTest -m CtsWidgetTestCases
Test: Added cts.TextViewTest#testAutosizeWithMaxLines_shouldNotThrowException
Test: Manual test with sample app for the failing case.
Bug: 38440435
Change-Id: Ic03c991f33a2b7701623f00f44cba7fb6cdfce46
Use the looper from the TextView's thread for the helper
Bug 62043115
Test: Manual, type on edit field and select text
Change-Id: I501430a500016a81963a9f9fa636474b708b9b36
See Ia9081d92ae9aea50d863455be770eecd0c73be1a for multi-selection
counts.
Test: Manually checked logging happens as per go/tron-howto and verified
nothing is broken in related classes by running:
bit FrameworksCoreTests:android.widget.TextViewActivityTest
bit CtsWidgetTestCases:android.widget.cts.TextViewTest
Bug: 32572232
Change-Id: I4ceab136ab73a20c6bc56732f7606ed103fe64d3