Commit Graph

8248 Commits

Author SHA1 Message Date
TreeHugger Robot
dc8c71b1df Merge "TextClassifier cross-user vulnerability in direct-reply" 2019-07-09 17:55:04 +00:00
Neil Fuller
658c88a6ce Merge "Switch widgets away from android.text.format.Time" am: db31e6d07a am: 8d96e17940 am: 19d4f4eb32
am: cc83885699

Change-Id: I65dbe328322adc5b17b93de7bb1ceb095e576582
2019-07-09 02:14:51 -07:00
Neil Fuller
cc83885699 Merge "Switch widgets away from android.text.format.Time" am: db31e6d07a am: 8d96e17940
am: 19d4f4eb32

Change-Id: I65336bde8f7730cb3aea8f436d5e301d808c52e6
2019-07-09 02:05:28 -07:00
Neil Fuller
8d96e17940 Merge "Switch widgets away from android.text.format.Time"
am: db31e6d07a

Change-Id: I550b2c7ac5e3e5b07eda51c190c354e5236a561e
2019-07-09 01:38:01 -07:00
Neil Fuller
db31e6d07a Merge "Switch widgets away from android.text.format.Time" 2019-07-09 08:15:10 +00:00
Abodunrinwa Toki
e8492693c2 TextClassifier cross-user vulnerability in direct-reply
Sys UI runs on user 0. This can lead to the TextClassifier (TC)
running for the wrong user. Consequencies are user A can launch apps
in user B via the TC's predicted actions and selected text being
unintentionally shared from user A to an app running in user B.

This fix ensures that the correct user id is passed and verified for
every TC request going across process boundaries (i.e. via SystemTC).
- Sys UI sets the appropriate user id in the TextView
- TextClassificationManager (TCM) system service is constructed using
  a context generated from this user id
- SystemTC sets this user id before querying the TCMService
- TCMService validates the user id before forwarding the request to
  the TCService belonging to that user id.

Bug: 136483597
Test: atest android.view.textclassifier
      atest android.widget.TextViewActivityTest
      (manual) Verified according to steps in bug 123232892
Change-Id: I2fdffd8eb4221782cb1f34d2ddbe41dd3d36595c
2019-07-08 15:16:19 +01:00
Qasid Sadiq
aabd50e0a4 Merge "Populate scrollX and scrollY on AccessibilityEvents." 2019-07-03 23:17:52 +00:00
Mathew Inwood
46f7f16a4d Merge "Restore some greylist entries." into qt-dev am: f76bdce6e0 am: 13ffa87a6d
am: 89f02cc81c

Change-Id: Ib5bc4e76d81ad69f7c3293e6cb72393e1aee7ed9
2019-06-28 09:36:40 -07:00
Mathew Inwood
89f02cc81c Merge "Restore some greylist entries." into qt-dev am: f76bdce6e0
am: 13ffa87a6d

Change-Id: I4c92e5685804a5b03510ab5b9396c0dc6f4aad46
2019-06-28 08:49:28 -07:00
Mathew Inwood
13ffa87a6d Merge "Restore some greylist entries." into qt-dev
am: f76bdce6e0

Change-Id: I320e33be57b8124ff7c132a67c8981d53802f8f5
2019-06-28 07:43:43 -07:00
Mathew Inwood
3a75f264a8 Restore some greylist entries.
In Q, these APIs were either:
- removed from the greylist entirely without good reason
- Moved to the restricted greylist without any public alternative
  information added

So they are being moved back to the greylist for Q.

Test: Treehugger
Bug: 136102585
Change-Id: I5ac8b8b9b23c3789d80239cf456072cc7dfa1203
2019-06-28 10:15:37 +01:00
Sergey
38d3e6fe26 Merge "Stable seek bar positioning" am: 874b481cdf am: ffb8583a65 am: d87bdf9834
am: a48ebd1dbc

Change-Id: Ie286b9a16b286fb3f453c8eee0897cce6382ac5b
2019-06-27 16:20:22 -07:00
Sergey
a48ebd1dbc Merge "Stable seek bar positioning" am: 874b481cdf am: ffb8583a65
am: d87bdf9834

Change-Id: I6c1596594271070901000f68e4500703560f6630
2019-06-27 15:59:30 -07:00
Sergey
d87bdf9834 Merge "Stable seek bar positioning" am: 874b481cdf
am: ffb8583a65

Change-Id: I049976100806ea78d99bad3201945ceccb0ee8c5
2019-06-27 15:40:25 -07:00
chaviw
9f6171e7b2 Deleted SurfaceControl.remove method
Updated all callers of SC.remove to use Transaction.remove(sc) and apply
immediately since that's the equivalent. Eventually, the transactions
that contain remove could combine with other transactions if it makes
sense to avoid duplicate applies.

Test: SurfaceControlTest
Change-Id: I13c6ec86de6a6d60f142c2269337557510dd006d
2019-06-25 17:09:03 -07:00
Qasid Ahmad Sadiq
002e3cf73a Populate scrollX and scrollY on AccessibilityEvents.
This wasn't happening for RecyclerView, and that resulted in lost focus after scroll animations.
This is cause Talkback relies on changes in getScrollX/Y to determine if it should do anything about a TYPE_VIEW_SCROLLED AccessibilityEvent.
This squashes a big subset of "losted focus" bugs.
This is most painfully felt when you fling a RecyclerView and in ViewPager page transition, both resulting in slightly longer animations.
Also, change the default value of m[Max]Scroll[x/y] to reflect the above.

Change-Id: Ibe66260fbfc61c98ca88e1b2d9552ed116e44c15
Fix: 125385883
Test: CTSAccessibility*, Tried a few RecyclerViews on device, and ViewPager2 sample app.
2019-06-25 06:32:58 +00:00
Sergey
24a89b4816 Stable seek bar positioning
Touching the thumb on the Seek bar prevents the thumb from immediately jumping to a new position and changing the progress of the Seek bar.

Test: Place your finger on the seek bar thumb so that your finger touches the thumb. Take your finger away. Seek bar should not change progress and thumb's position.
Place your finger on the seek bar thumb so that your finger touches the thumb. Seek bar should not change progress and thumb's position. Then, without lifting your finger from the screen, move your finger towards the maximum or minimum value. Seek bar thumb should follow your finger while maintaining its position relative to your finger.

Change-Id: Ia72d247662ad5b8dd66d0b0578098b9a2b6060cd
2019-06-21 16:20:27 +04:00
Neil Fuller
0bab7fa512 Switch widgets away from android.text.format.Time
android.text.format.Time is limited to 32-bit seconds from the
beginning of the Unix epoch and so classes that use it are limited
to 1901 - 2038. Switching to java.time avoids this issue.

Manual Testing:

AnalogClock is deprecated and not used anywhere so difficult to
test.

DateTimeView is used in the status bar. Behavior was verified with
current date/time and also Europe/London around 2019-03-31 01:00
(skip forward) and around 2019-10-27 02:00 (fall back). The time picker
in settings uses android.icu.util.Calendar which favored the later time
if there are two local times with the same display time (e.g. the
fall back case). The "repeat" case was tested with "date @1572137900"
to set the clock to "the first" 01:58, then waiting 2 minutes to
ensure that the 01:59 -> 01:00 transition occurs correctly.

Bug: 16550209
Test: build / boot / treehugger
Test: See above
Change-Id: Ibadad3041a2e54fe12d347960bf1e0f3ebe10c01
2019-06-18 15:29:41 +01:00
Mihai Popa
c4db4d8416 Merge "[Magnifier-87] Fix deadlock causing ANR" into qt-dev am: 9550c185f9
am: 8cb39cbec2

Change-Id: I549a844a9fdf1cc8ab480188c71005e7d47e54f4
2019-06-18 02:30:42 -07:00
Mihai Popa
8cb39cbec2 Merge "[Magnifier-87] Fix deadlock causing ANR" into qt-dev
am: 9550c185f9

Change-Id: I5aa641b8ed1a13605f6311d10a06f964ede29522
2019-06-18 02:22:45 -07:00
Mihai Popa
c00e2718d0 Merge "[Magnifier-87] Fix deadlock causing ANR" 2019-06-17 21:13:15 +00:00
Mihai Popa
e42215ea70 [Magnifier-87] Fix deadlock causing ANR
Before this CL, the magnifier could deadlock when the following
happened:
1. the renderer is asked to draw (and a frame callback is provided)
2. a #dismiss() happens on the UI thread. This acquires mDestroyLock
(previously line 309)
3. InternalPopupWindow#destroy() is called, and this calls
mRenderer.destroy(). This attempts to destroy the renderer on the UI
thread, however the UI thread will wait until the pending frame callback
corresponding to step 1 is executed on the render thread.
4. The frame callback starts executing on the render thread, and tries
to acquire mDestroyLock (previously line 1093). However, this is held by
the UI thread, so a deadlock happens.

This CL completely removes mDestroyLock, relying on the existing
synchronization between the UI and render threads described in step 3.

Bug: 134584742
Test: manual testing
Change-Id: Ia4c75b5b997e0ed94d5a3814dd4507a8fffa124d
2019-06-17 11:59:20 +00:00
Mihai Popa
afee43bfa1 [Magnifier-87] Fix deadlock causing ANR
Before this CL, the magnifier could deadlock when the following
happened:
1. the renderer is asked to draw (and a frame callback is provided)
2. a #dismiss() happens on the UI thread. This acquires mDestroyLock
(previously line 309)
3. InternalPopupWindow#destroy() is called, and this calls
mRenderer.destroy(). This attempts to destroy the renderer on the UI
thread, however the UI thread will wait until the pending frame callback
corresponding to step 1 is executed on the render thread.
4. The frame callback starts executing on the render thread, and tries
to acquire mDestroyLock (previously line 1093). However, this is held by
the UI thread, so a deadlock happens.

This CL completely removes mDestroyLock, relying on the existing
synchronization between the UI and render threads described in step 3.

Bug: 134584742
Test: manual testing
Change-Id: Ia4c75b5b997e0ed94d5a3814dd4507a8fffa124d
2019-06-17 12:46:16 +01:00
Qasid Ahmad Sadiq
addec39fb7 Merge "Disabled items shouldn't also be marked as unactionable." into qt-dev am: 0963cc2418 am: f695023309
am: 315cd7d00f

Change-Id: Ia47380572b48df0d43f923791c1750b59cc3cb3c
2019-06-12 14:24:30 -07:00
Qasid Ahmad Sadiq
315cd7d00f Merge "Disabled items shouldn't also be marked as unactionable." into qt-dev am: 0963cc2418
am: f695023309

Change-Id: Ic6d82df2a5d16235acf241f845274c8a844cb5e8
2019-06-12 13:42:15 -07:00
Qasid Ahmad Sadiq
41f0326426 Merge "Disabled items shouldn't also be marked as unactionable." into qt-dev
am: 0963cc2418

Change-Id: Icd80b77ff7e7b7d6cadecb914609e90fab2b9a8e
2019-06-12 13:26:41 -07:00
Qasid Ahmad Sadiq
f695023309 Merge "Disabled items shouldn't also be marked as unactionable." into qt-dev
am: 0963cc2418

Change-Id: I990a85b223694123bbf9114e038373253fd4f25f
2019-06-12 13:26:09 -07:00
TreeHugger Robot
0963cc2418 Merge "Disabled items shouldn't also be marked as unactionable." into qt-dev 2019-06-12 20:10:31 +00:00
Qasid Ahmad Sadiq
08de63ea45 Disabled items shouldn't also be marked as unactionable.
Something can be clickable and disabled. Returning early here prevents that state to be reflected in ListView items.
The reported bug was happening because the items were disabled, but they weren't being reported as clickable.
Talkback doesn't read "disabled" for disabled items unless they are also actionable in certain ways.
Test: CTSAccessibility*, CTS AbsListViewTest, CTS ListViewTest, tried UI with sample app.
Fix: 131281972

Change-Id: Ic9b8c995398151f084d194e272ce082ec345e517
2019-06-11 18:58:21 -07:00
Adam Powell
2541038909 Merge "Gesture exclusion for seekbar thumbs/edit handles" into qt-dev am: 2b2d6f58c1 am: 076200294d
am: b2e12dec14

Change-Id: Id9d305327690ad41501c31d474790c9a92d332e8
2019-06-11 14:15:53 -07:00
Adam Powell
b2e12dec14 Merge "Gesture exclusion for seekbar thumbs/edit handles" into qt-dev am: 2b2d6f58c1
am: 076200294d

Change-Id: Iae84b29fe0d4e0e8e6874114944b981a9911c34a
2019-06-11 14:09:19 -07:00
Adam Powell
076200294d Merge "Gesture exclusion for seekbar thumbs/edit handles" into qt-dev
am: 2b2d6f58c1

Change-Id: I7485be0f36776fd3cd08aa4b3b20b7bf623c5eb1
2019-06-11 13:46:21 -07:00
Adam Powell
a5eec588e8 Merge "Gesture exclusion for seekbar thumbs/edit handles" into qt-dev
am: 2b2d6f58c1

Change-Id: Iff04c752c71fbc3106df698394e2da8db2783d47
2019-06-11 13:42:02 -07:00
Adam Powell
8624121b27 Gesture exclusion for seekbar thumbs/edit handles
Track gesture exclusion rects for seekbars and EditText selection and
cursor handles.

Bug: 133845668
Bug: 129338678
Test: cts/manual
Change-Id: I029d8ba465459f8ecaa14ee8ad0f5f4139b24e65
2019-06-10 20:24:20 +00:00
Feng Cao
d57c9734ec Merge "Only send text update for TextView after VIEW_ADDED is notified" into qt-r1-dev am: 691fa971ec
am: a1a275e63c

Change-Id: Ie5e4104e6111c3a5d326e621c2528ece42879ebf
2019-06-08 11:11:54 -07:00
Feng Cao
a1a275e63c Merge "Only send text update for TextView after VIEW_ADDED is notified" into qt-r1-dev
am: 691fa971ec

Change-Id: I7cd136b96fa62c79557768ecd1f75243bb75c670
2019-06-08 11:06:53 -07:00
Feng Cao
9e4ca44e28 Only send text update for TextView after VIEW_ADDED is notified
Test: atest CtsContentCaptureServiceTestCases (sanity check)
Fixes: 134309443

Change-Id: Ia94194576db0a1679bbb2a9b76c84a871b965435
2019-06-08 00:56:43 +00:00
Aurimas Liutikas
b51c200cf9 Merge "Record textAppearance information for TextView." into qt-dev am: e53837182c am: c38e9716a8
am: 6fa3d16fda

Change-Id: Idbe6319682a7475541819c340d1841008ccc1063
2019-06-07 16:07:53 -07:00
Aurimas Liutikas
6fa3d16fda Merge "Record textAppearance information for TextView." into qt-dev am: e53837182c
am: c38e9716a8

Change-Id: I82607f8843f5f34a4f169efcb6cf0836738c6d53
2019-06-07 16:01:31 -07:00
Aurimas Liutikas
0e85874ef5 Merge "Record textAppearance information for TextView." into qt-dev
am: e53837182c

Change-Id: I9c6ba6e4cd9c13030cc31c16b05cfdf2f4a25c1d
2019-06-07 15:51:36 -07:00
Aurimas Liutikas
c38e9716a8 Merge "Record textAppearance information for TextView." into qt-dev
am: e53837182c

Change-Id: I93a7c449a72bab5f25690505453432b551e3ff94
2019-06-07 15:51:30 -07:00
TreeHugger Robot
e53837182c Merge "Record textAppearance information for TextView." into qt-dev 2019-06-07 22:35:55 +00:00
Sunny Goyal
1a9fa0380b Merge "Resetting widget cache when some configurations change" into qt-dev am: 5cb8996742 am: 0dc76428f8
am: 71afd32213

Change-Id: If2ce6af8fb82379814bf43e9140ced4562bc36f1
2019-06-07 11:47:17 -07:00
Sunny Goyal
71afd32213 Merge "Resetting widget cache when some configurations change" into qt-dev am: 5cb8996742
am: 0dc76428f8

Change-Id: I8d58a14815be7afa8c6f905af15c3d8ce31286f9
2019-06-07 11:42:31 -07:00
Sunny Goyal
7cf40fc0fe Merge "Resetting widget cache when some configurations change" into qt-dev
am: 5cb8996742

Change-Id: I8f3b1ab541a0398191c1110dc1f8d6d1fb7786e5
2019-06-07 11:37:32 -07:00
Sunny Goyal
0dc76428f8 Merge "Resetting widget cache when some configurations change" into qt-dev
am: 5cb8996742

Change-Id: If13799bd7bde4a39744c355c1766e602cb9e7de9
2019-06-07 11:37:31 -07:00
Sunny Goyal
758e88bd44 Resetting widget cache when some configurations change
Sometimes widget providers hardcode colors in their remoteViews
by loading them from resources. On UI mode change, this can lead to
inconsistent UI if some widgets use a different configuration
than others.

Test: Verified with calendar widget on device
Bug: 133064045
Change-Id: If47a6b1973f55b7590f5d4116813d6a332951697
2019-06-06 17:02:55 -07:00
Torne (Richard Coles)
a759af55a4 Merge "Clarify problems with Linkify.MAP_ADDRESSES." into qt-dev am: a0d66cf3f6 am: 0f0173f9e1
am: c2ed59a2da

Change-Id: Ibc2165020ad583db1c4488e68f8d688e9d7a8fe5
2019-06-06 11:13:16 -07:00
Torne (Richard Coles)
c2ed59a2da Merge "Clarify problems with Linkify.MAP_ADDRESSES." into qt-dev am: a0d66cf3f6
am: 0f0173f9e1

Change-Id: Ib8f8c29444f9cf6e1c4de4c15d3a0b4d12632556
2019-06-06 11:02:29 -07:00
Torne (Richard Coles)
0f0173f9e1 Merge "Clarify problems with Linkify.MAP_ADDRESSES." into qt-dev
am: a0d66cf3f6

Change-Id: I10e7f3f8d14d15e3dbc5fd6f97bafc7442c91bb4
2019-06-06 10:59:15 -07:00