Commit Graph

4799 Commits

Author SHA1 Message Date
Alan Viverette
ff44188309 Merge "Improve time picker accessibility" into lmp-mr1-dev 2014-12-11 22:11:56 +00:00
Alan Viverette
e6ec07fc5d Always call onDateChanged() when the date picker selection changes
BUG: 18703635
Change-Id: I2f71aa2e3e053cc8afd1bb84641a9fb29de89c72
2014-12-10 11:24:27 -08:00
Alan Viverette
3fc00e3139 Improve time picker accessibility
Overrides click action description for TimePicker hour/minute selectors
and manually specifies traversal order for radial time picker nodes.

BUG: 17468036
Change-Id: I4472b42a95d762085d7a4d382feb2b9216c0d41c
2014-12-10 09:46:49 -08:00
Alan Viverette
7781647aa9 Merge "Fix auto-advance regression in radial time picker" into lmp-mr1-dev 2014-12-09 00:08:01 +00:00
Alan Viverette
11a68e1803 Fix auto-advance regression in radial time picker
If autoAdvance is set, we need to always fire the listener. We should
create a separate callback for auto-advance, but this is a minimal fix.

BUG: 18654878
Change-Id: Ie7b8a3ff91761325a508f580b27fa3b08f7b4e16
2014-12-08 15:54:38 -08:00
Alan Viverette
882a1e8974 Merge "Let host view handle long-press when using drag-to-open" into lmp-mr1-dev 2014-12-08 21:29:08 +00:00
Alan Viverette
db82c9e00e Merge "Fix regression, don't NPE if Switch doesn't have a thumb set" into lmp-mr1-dev 2014-12-08 21:29:04 +00:00
Svet Ganov
381a423634 Merge "When accessibility on cannot click on a view covered by a HorizontalScrollView" into lmp-mr1-dev 2014-12-08 21:28:19 +00:00
Alan Viverette
01a0963006 Fix regression, don't NPE if Switch doesn't have a thumb set
BUG: 18670202
Change-Id: Iecb3498032c121c007ec87740ddebadb8e71c7a3
2014-12-08 13:02:06 -08:00
Alan Viverette
298536b1a0 Let host view handle long-press when using drag-to-open
BUG: 18605860
Change-Id: I75850138614f17cf728d4411c142a07bdf15d085
2014-12-08 12:31:14 -08:00
Alan Viverette
b942b6f15c Fix hotspot coordinate propagation in ViewGroup and AbsListView
There was a weird disconnect between setPressed() and hotspot propagation
behavior. This makes hotspot propagation work like setPressed(). Also
fixes ripple animation during drag-to-open.

BUG: 18631557
BUG: 18593243
Change-Id: Id4adf5d815e4d426b4182aac4d0c780f04472ae4
2014-12-08 10:37:39 -08:00
Svet Ganov
b3fa2787ea When accessibility on cannot click on a view covered by a HorizontalScrollView
In accessibility mode we send down and up events activate a view. We will later
switch to accessibility actions but for now as a bridge-gap we compute a point on
the screen where to click for activating the view. The heuristic we use has edge
cases such as a view that handles all touch events but does not have any listeners.
In this case we do not ignore the target view's area covered by a view that handles
all touch events. As a result we click on the wrong target. While we cannot solve
this generically, in the case of standard components such as HorizontalScrollView
we can.

bug:18612258

Change-Id: If8482aac0d0ea53c5c90367d099d1b8d3a4559ed
2014-12-05 13:13:15 -08:00
Alan Viverette
9752428dc1 Use CURRENT_OR_SELF when checking SPEAK_PASSWORD setting
Using CURRENT isn't always safe.

BUG: 18557273
Change-Id: I12e197ab25b8ffdc04c5e74836945177870698a2
2014-12-02 16:24:24 -08:00
Alan Viverette
002f918cea Only send haptic events from time picker when time changes
BUG: 18572841
Change-Id: Iaa26e2f0804e301f8754e19a1d03dbd2142bf044
2014-12-01 16:13:32 -08:00
Alan Viverette
0a310c99ee Merge "Revert "Animates AbsSeekBar progress movement from key presses."" into lmp-mr1-dev 2014-11-26 00:52:36 +00:00
Alan Viverette
5ce0ec0efd Revert "Animates AbsSeekBar progress movement from key presses."
Incorrect implementation that broke the Brightness dialog slider. Reverting
to the previous behavior.

This reverts commit c5c9d0af764f590ae0031b5470192a0a08ca42d1.

BUG: 18510040
Change-Id: I201b1da46be964fcf6f041bb92ef79c335c2d23d
2014-11-26 00:36:26 +00:00
Alan Viverette
b6e0cb97b7 Load SPEAK_PASSWORD from currently active user rather than self
Also fixes a typo in UserHandle's docs.

BUG: 18295054
Change-Id: I1f5384f84062b9ea7dcbebe1e5f64af331028d41
2014-11-25 16:08:03 -08:00
Alan Viverette
27fbf67644 Merge "Update documentation for DatePicker to reflect the new mode" into lmp-mr1-dev 2014-11-25 00:50:50 +00:00
Alan Viverette
d25eb9fbb9 Update documentation for DatePicker to reflect the new mode
BUG: 18508605
Change-Id: I23d45bf1cd7783fa6f397c15f0ba6802e4069d6b
2014-11-24 14:07:24 -08:00
Selim Cinek
962b06f9a0 Merge "Fixed several time related states for secondary users" into lmp-mr1-dev 2014-11-24 11:52:40 +00:00
Yigit Boyar
ace33655bf Merge "Improve GridLayout's weight calculations" into lmp-mr1-dev 2014-11-21 20:48:45 +00:00
Selim Cinek
9c4a707912 Fixed several time related states for secondary users
The 24 hour setting was not respected correctly. Also
fixed a bug where the next alarm would not display itself
in the QS panel.

Bug: 16239208
Change-Id: I89734f783912dead5831db49db53fba04dbf54ee
2014-11-21 18:25:30 +01:00
Alan Viverette
8ae8500365 Merge "Update scrollbars to match Material spec" into lmp-mr1-dev 2014-11-21 02:12:10 +00:00
Alan Viverette
199ea8c0c7 Update overflow menu alignment to match spec
BUG: 18417348
Change-Id: I5e4b1ca366c554bca33eac8e5403be6de72370f9
2014-11-20 17:09:27 -08:00
Alan Viverette
7d5bcd7990 Update scrollbars to match Material spec
Adds a minimum touch target size to the fast scroller so that we can
edge-align an 8dp thumb but still maintain a 48dp touch target.

BUG: 18467743
Change-Id: I31e9cf1948856f5fce7d75383b84a9359684ebe5
2014-11-20 16:07:59 -08:00
Alan Viverette
b130d5961c Merge "Remove underline and search icon from ActionBar search view" into lmp-mr1-dev 2014-11-19 23:52:24 +00:00
Alan Viverette
552eca1a71 Merge "Implement Material-style delegate for CalendarView" into lmp-mr1-dev 2014-11-19 23:51:34 +00:00
Yigit Boyar
98d5f04f91 Improve GridLayout's weight calculations
This CL improves the method by which excess space is distributed in GridLayout.
Previously, GridLayout would assume weights were arranged in a 'line' and
sum the weights in the assumed line to figure out the proportional allocation
to each view. The system involved running GridLayout's internal constraint 
solver twice.

Behavior was unspecified (and surprising) when weights appeared in views
that were not linked together linearly, typically leaving the last view 
in each axis with more space than expected (in GridLayout's Bellman-Ford 
constraint solver, remaining space goes to the last span of the axis).

This CL changes the weight distribution mechanism to effectively integrate it
with the Bellman-Ford constraint resolution algorithm. It does this
by returning a boolean value from the constraint solver saying whether or
not the constraints could be solved and then using a binary chop to find 
a maximum amount of space that can be distributed without violating the 
constraints.

This implementation runs the solver log(<axis size> * <number of Views>)
times until finding the maximum amount of space that can be distributed according
to the weights without causing a contradiction. We expect the cost of this
variation to be around a factor of 10 worse than the previous implementation
but to provide a simple and general definition of space distribution via
weights that will be open to many future optimizations.

As a side effect, this CL also fixes a bug in GridLayout where remaining space
was distributed only along the major axis.

Bug: 17485996
Change-Id: I120f39e95e90b5b35072ef8a6c348ec541aae42a
2014-11-19 03:23:18 +00:00
Alan Viverette
a489f0b3d9 Merge "Re-initialize data when changing time picker 24-hour mode" into lmp-mr1-dev 2014-11-19 02:28:37 +00:00
Alan Viverette
448ff718a0 Re-initialize data when changing time picker 24-hour mode
BUG: 18381313
Change-Id: Ie1fa9fbbf8edadfda71cf0ad4f1c39395e56ecc7
2014-11-18 18:28:04 -08:00
Alan Viverette
cb8ed3705c Remove underline and search icon from ActionBar search view
BUG: 17396265
Change-Id: I751bc79538f1ea412192172035920e59351270f1
2014-11-18 17:05:35 -08:00
Alan Viverette
68235e4dbc Merge "Prevent NPE when computing FastScroller position with no visible items" into lmp-mr1-dev 2014-11-18 17:46:52 +00:00
Raph Levien
25f7c4b992 Merge "Update hint text color even when text present" into lmp-mr1-dev 2014-11-14 20:53:14 +00:00
Raph Levien
cda81f2ded Merge "Fudge clipRect in TextView for extra cursor width" into lmp-mr1-dev 2014-11-14 20:51:58 +00:00
Alan Viverette
df68999dc7 Don't dismiss AutoCompleteTextView on focus change while temp detached
This is consistent with how TextView handles focus changes while
temporarily detached and prevents the suggestion popup from being
dismissed during layout when the AutoCompleteTextView is used
within a ListView.

BUG: 18364277
Change-Id: I8ca6fb9dba63b49a84a60a606bc441446c083cee
2014-11-13 12:59:37 -08:00
Raph Levien
44cb2432e9 Fudge clipRect in TextView for extra cursor width
There are a number of cases (most commonly cursor at start of line in
RTL direction) where the cursor extends past the right edge of the
clipRect. This patch adds approximately 1dp on the right side of the
clip, so that the cursor doesn't get clipped.

Bug: 18035274
Change-Id: I489825a91750742c28e445f54f9d27000accbcfb
2014-11-13 12:48:40 -08:00
Alan Viverette
4612740ddc Implement Material-style delegate for CalendarView
BUG: 18266649
Change-Id: Ifd749328754b82dc43259ca7dadb472e449bdfff
2014-11-13 10:50:37 -08:00
Alan Viverette
827015edb3 Prevent NPE when computing FastScroller position with no visible items
BUG: 18371212
Change-Id: I90b1f540cdc6095e18242b879c50e8060de662ee
2014-11-13 10:26:53 -08:00
Raph Levien
c1bf285966 Update hint text color even when text present
When text is present (so the hint doesn't show), updating the hint color
was suppressed. This patch updates the hint color in all cases, but
still skips the invalidate when the hint text is not showing.

Bug: 17454233
Change-Id: I3887908fb184a10f7a1d7e64f1d92b4955323227
2014-11-12 12:41:24 -08:00
Alan Viverette
4fc2ea8402 Merge "Ensure time picker dialog fits on small screens" into lmp-mr1-dev 2014-11-12 17:32:31 +00:00
Alan Viverette
d9f3fdf45b Ensure time picker dialog fits on small screens
Also fixes dialog padding in landscape mode and a bug in the
ColorStateList method used to apply a selected color.

BUG: 18251582
Change-Id: Id5b8c7893ec42fd4d5f4a7520e6ac170839d3143
2014-11-12 09:31:22 -08:00
Alan Viverette
993e3d2d40 Merge "Call OnTimeChangedListener when new TimePicker values are selected" into lmp-mr1-dev 2014-11-10 23:54:47 +00:00
Alan Viverette
c0bf068bbf Merge "Clean up encapsulation in date picker classes" into lmp-mr1-dev 2014-11-10 18:29:29 +00:00
Alan Viverette
82aaf332b6 Merge "Update above/below backgrounds in PopupWindow.setBackground()" into lmp-mr1-dev 2014-11-10 17:18:49 +00:00
Alan Viverette
73c3068b0e Call OnTimeChangedListener when new TimePicker values are selected
BUG: 18295303
Change-Id: Ib5922db3a16c1975554072e2af241bbd6cf807c4
2014-11-07 15:39:24 -08:00
Adam Powell
740da4753a Don't register more receivers and observers for every DateTimeView
SystemUI uses several of these per notification, so be a little more
conservative and track individual views to update per process instead.

Bug 16902706

Change-Id: Ib77a8e7727d027cae39d5e6f431cac1d1ff8a121
2014-11-07 14:56:43 -08:00
Alan Viverette
ce8c358712 Update above/below backgrounds in PopupWindow.setBackground()
BUG: 17718714
Change-Id: I936dfede60bc006a59cd3eb1b18548c7702ae0ee
2014-11-07 13:19:38 -08:00
Alan Viverette
e763c9bd6e Clean up encapsulation in date picker classes
First step to replacing CalendarView with DayPickerView. Removes
dependencies on the DatePickerController class and adds setters
and listeners needed to hook up to DatePicker or CalendarView.

BUG: 18266649
Change-Id: Ic215f96eaddc0048040ec6bca0d85b776216fd26
2014-11-06 15:22:31 -08:00
Alan Viverette
aa33a487c8 Merge "Always update date picker position after change in range" into lmp-mr1-dev 2014-11-05 00:00:52 +00:00
Alan Viverette
5ecbfeb38b Always update date picker position after change in range
BUG: 18204507
Change-Id: Id3ae11cdb68f60901a3145ebd93f3acbbccd71d2
2014-11-03 18:31:36 -08:00