Commit Graph

5915 Commits

Author SHA1 Message Date
Alan Viverette
895615c363 Ensure layout resolution occurs when relative rules are removed
Bug: 23295655
Change-Id: Ic46b018859c5af8cabf2fa0677e002de7cb6a996
2015-08-18 14:51:48 -04:00
Alan Viverette
d920ac6e6f Merge "Use correct param for heightMode in RelativeLayout horizontal measure" 2015-08-18 13:28:44 +00:00
Yohei Yukawa
9dffc27b60 Merge "Clear SuggestionsPopupWindow.mSpansLengths after it is used." 2015-08-17 21:44:24 +00:00
Alan Viverette
46fb1249bc Merge "Separate TabWidget selection from keyboard focus" 2015-08-17 20:44:17 +00:00
Alan Viverette
760a2d845a Re-enable TAB traversal in ListView
This makes navigation asymmetrical, but that's preferable to navigation
straight-up not working at all.

Bug: 14392811
Change-Id: Ifbb41adabdc9e015c8ed7195cbfb92ec0d8458a0
2015-08-17 14:31:42 -04:00
Alan Viverette
1352a36bee Separate TabWidget selection from keyboard focus
Also removes a bunch of weird accessibility hacks that shouldn't have
been there in the first place.

Bug: 19382871
Change-Id: I8cbdfb6e2dab98cc88028dff5bc23376c98a077a
2015-08-17 14:23:10 -04:00
Alan Viverette
d78036bbec Add accessors for TabWidget strip drawables
Change-Id: Ia6aef6a2221096c2653ae39fcec60289fa0ee2fb
2015-08-14 13:53:56 -04:00
Alan Viverette
7eb09d15cc Clean up TabWidget
No functional changes, just refactoring and cleaning up comments.

Actually, just one functional change so that setting the tab strip to
@empty will actually remove the tab strip drawable. This makes it
consistent with passing null to the accessor method.

Change-Id: I6f5ba8bea4e8b30117de5f12a86957e995812cfe
2015-08-14 11:36:01 -04:00
Alan Viverette
eff1b7175d Merge "Add popup theme to AutoCompleteTextView, clean up constructor" 2015-08-13 13:29:19 +00:00
Raph Levien
8cf6d865cf am d202d15d: am cf2d44be: am 855a862f: am c98a786c: am beabcb92: Merge "Fix Insertion ActionMode not showing on RTL languages" into mnc-dev
* commit 'd202d15d9e4845537c4409c9880eb269b2b59129':
  Fix Insertion ActionMode not showing on RTL languages
2015-08-12 21:40:58 +00:00
Raph Levien
d202d15d9e am cf2d44be: am 855a862f: am c98a786c: am beabcb92: Merge "Fix Insertion ActionMode not showing on RTL languages" into mnc-dev
* commit 'cf2d44bee50dc2950181bbf5974c32eacea6f0a7':
  Fix Insertion ActionMode not showing on RTL languages
2015-08-12 21:31:07 +00:00
Yohei Yukawa
67af994c6c Clear SuggestionsPopupWindow.mSpansLengths after it is used.
This is a no risk optimization that minimizes the time when
strong references to SuggestionSpan and Integer instances are
hold in SuggestionsPopupWindow.mSpansLengths.

SuggestionsPopupWindow.mSpansLengths are used while the given
SuggestionSpans array is being sorted. We don't need to keep
object references there after the sort is completed.

No user visible change is intended with this CL.

Change-Id: I7882d741c08d07ad7f905ad1d171c0d13da39397
2015-08-12 13:55:37 -07:00
Alan Viverette
c60feca6a9 Clear check mark resource ID when set from Drawable object
Bug: 22626247
Change-Id: Ia32bc19512442fdf0d2c091d63a61f992545f2c2
2015-08-12 16:26:37 -04:00
Clara Bayarri
f95ed10d9d Fix Insertion ActionMode not showing on RTL languages
When long pressing on an empty Text field with the system language set
to RTL, the "paste" popup was not showing up.

The Floating Toolbar requires a content rect to determine where the
text is and place itself close to it. In the case of an empty field,
we create a "fake" content rect by taking the placement of the cursor
+1 pixel to the right. In RTL languages, this +1 causes the content
rect to be considered off the bounds of the view, as the cursor is
aligned to the right, and hence the Floating Toolbar is hidden.

After making the rect a 0 width rect, we ran into the issue that
it was considered out of bounds due to the calculation ignoring rects
that simply touch the edge of the view's bounds.

BUG: 22540083
Change-Id: I29c79b701f586970b2611178233eff082b802ec1
2015-08-12 21:03:28 +01:00
Alan Viverette
130ce740d1 Use correct param for heightMode in RelativeLayout horizontal measure
Bug: 22824701
Change-Id: Ia0afd3edc20b8127605aef2653fa9b5472f41be2
2015-08-12 13:04:16 -04:00
Alan Viverette
da6b2f6ccb Add popup theme to AutoCompleteTextView, clean up constructor
Bug: 22912507
Change-Id: I48d8b1ccae980847c743020d3f2a0d2eb6017e40
2015-08-12 11:26:15 -04:00
Alan Viverette
cd703b6235 Clean up Spinner constructor docs, final class vars
Change-Id: I8c7eef08718474bbdebe8eceaf34ebac4007d945
2015-08-12 11:14:33 -04:00
Seigo Nonaka
62aeada120 Use TextUtils.substring instead of String.substring.
This is a small refactoring of using substring method.
Calling TextUtils.substring is more efficient than calling
toString and String.substring.

Change-Id: I0a740b2a2fdbfb6b6155c4e926e17889025082f5
2015-08-07 16:42:22 -07:00
Alan Viverette
42a5284cc8 Merge "Always set switch state following drag" 2015-08-07 15:45:37 +00:00
Alan Viverette
03306a0b27 Always set switch state following drag
Bug: 23029815
Change-Id: Ic291803f02cab2a9ccb96622ac0569e1c78c7291
2015-08-07 11:34:25 -04:00
Alan Viverette
400997be3c am 1da56c0b: am 3fd42737: am 8a782c9d: am db576e1d: am c7f8133f: Merge "Update anchor background on the correct view in PopupWindow" into mnc-dev
* commit '1da56c0bc9d30649e255d721428a95b79fa668b2':
  Update anchor background on the correct view in PopupWindow
2015-08-06 18:28:25 +00:00
Alan Viverette
1da56c0bc9 am 3fd42737: am 8a782c9d: am db576e1d: am c7f8133f: Merge "Update anchor background on the correct view in PopupWindow" into mnc-dev
* commit '3fd42737b77e499a0f8ed5ef8aa14ebdcf5f7767':
  Update anchor background on the correct view in PopupWindow
2015-08-06 18:19:40 +00:00
Alan Viverette
c7f8133fa1 Merge "Update anchor background on the correct view in PopupWindow" into mnc-dev 2015-08-06 17:48:22 +00:00
Chet Haase
950af418c3 am ddc15988: am f7d8577e: am 42c70645: am aed2e8ba: am da493aa6: Merge "Avoid changing internal state of shared drawable" into mnc-dev
* commit 'ddc1598871be09e132dc49dba011d38007c4335b':
  Avoid changing internal state of shared drawable
2015-08-06 16:56:52 +00:00
Chet Haase
ddc1598871 am f7d8577e: am 42c70645: am aed2e8ba: am da493aa6: Merge "Avoid changing internal state of shared drawable" into mnc-dev
* commit 'f7d8577ed048361ffac711a721acc69f83ab6e01':
  Avoid changing internal state of shared drawable
2015-08-06 16:50:40 +00:00
Alan Viverette
697804e8de Update anchor background on the correct view in PopupWindow
We were always setting the background of the decor view when the
"above anchor" state changed, rather than the background view.

Bug: 22970244
Change-Id: I3cd7202767ee47cb415736bb3c07369801abccd8
2015-08-06 12:36:47 -04:00
Chet Haase
da493aa6ea Merge "Avoid changing internal state of shared drawable" into mnc-dev 2015-08-06 16:23:20 +00:00
Chet Haase
bfa11e4ab8 Avoid changing internal state of shared drawable
An optimization in ImageView nulled out the internal bitmap of a cached
internal BitmapDrawable object created to wrap a bitmap set on the ImageView.
However, apps can get ahold of that cached object via Drawable.getBitmap(),
resulting in having the state of that object they may be using changing out
from under them.

The change is to null out the cached object when getDrawable() is called, to avoid
leaking internal state that we may change.
That way, the app can continue to use that object if they want to, but we are no longer
relying on it internally, and will create a new one when needed.

Issue #22930646  [1P Regression from L] ImageView is blanked out in Activity in Google Express

Change-Id: Ic86cb93be4897b6ba247c1fabcda507e4ba01300
2015-08-06 07:55:24 -07:00
Vladislav Kaznacheev
e789a314d1 am e07e684f: am 469840aa: am c3213285: am 072097bd: am 8cc00243: Merge "Keep OverScroller.SplineOverScroller state consistent." into mnc-dev
* commit 'e07e684f43665a19d0494d10dbc1e25129ca242b':
  Keep OverScroller.SplineOverScroller state consistent.
2015-08-05 20:36:58 +00:00
Vladislav Kaznacheev
e07e684f43 am 469840aa: am c3213285: am 072097bd: am 8cc00243: Merge "Keep OverScroller.SplineOverScroller state consistent." into mnc-dev
* commit '469840aa48e30d96a1f5329d38e177ab18b924d9':
  Keep OverScroller.SplineOverScroller state consistent.
2015-08-05 20:07:54 +00:00
Vladislav Kaznacheev
84ad7e9ee2 Keep OverScroller.SplineOverScroller state consistent.
Currently update() bails out early if it is called
too soon after mStartTime has been set. In this case
mCurrentPosition remains holding an obsolete value
from a previous animation. This causes some strange
behavior (see the referenced bug).

This patch makes sure that mCurrentPosition is
updated every time that mStart is updated.

Bug: 22950559
Change-Id: I07b92f30ebe29856f4e04dc19a4820123713fd7e
2015-08-04 21:24:59 +00:00
Alan Viverette
6d163bcce5 am f2fea136: am dbb79ae9: am 4cf97c91: am 7bfe7b5b: am 5cca30a4: Merge "Revert two changes to LinearLayout measurement" into mnc-dev
* commit 'f2fea1363b239dbfbd21f9449cfde8542320a34a':
  Revert two changes to LinearLayout measurement
2015-08-01 17:54:19 +00:00
Dianne Hackborn
f6f1a7ec99 am 628b4125: am bc2a8843: am b97c5ddd: am 9b36f526: am c1836bb0: Merge "Change MNC codename to just M." into mnc-dev
* commit '628b4125843b93dc7f3ed0c9bbea76ff470d2eed':
  Change MNC codename to just M.
2015-08-01 17:53:09 +00:00
Alan Viverette
f2fea1363b am dbb79ae9: am 4cf97c91: am 7bfe7b5b: am 5cca30a4: Merge "Revert two changes to LinearLayout measurement" into mnc-dev
* commit 'dbb79ae9dc457bcb97794f718c6d3aa7fc4a19ca':
  Revert two changes to LinearLayout measurement
2015-08-01 17:05:28 +00:00
Dianne Hackborn
628b412584 am bc2a8843: am b97c5ddd: am 9b36f526: am c1836bb0: Merge "Change MNC codename to just M." into mnc-dev
* commit 'bc2a88431e3dc51e2245cc28e327f11d0c78bd56':
  Change MNC codename to just M.
2015-08-01 17:04:28 +00:00
Alan Viverette
5cca30a4ee Merge "Revert two changes to LinearLayout measurement" into mnc-dev 2015-07-31 21:30:48 +00:00
Dianne Hackborn
c1836bb0f1 Merge "Change MNC codename to just M." into mnc-dev 2015-07-31 17:11:58 +00:00
Alan Viverette
5a969dfd8e Revert two changes to LinearLayout measurement
"Include non-zero dimension views in excess space calculation" and
"Always distribute excess space in LinearLayout measurement" changed
LinearLayout behavior significantly in a way that wasn't covered by
CTS tests.

This reverts commits da2f304409 and
4fabc02158.

Bug: 22862047
Change-Id: I8d37a525ccf295445d3239b80e5cacb10bf3c947
2015-07-31 12:42:10 -04:00
Dave Langemak
1b748f77d3 am 66cff122: am 2e802cac: am 72dcb47d: am b880a036: am 02565c36: Merge changes from topic \'fix-notification-inflation-2\' into mnc-dev
* commit '66cff122cc6d123b947be5f28186dc233a7be1aa':
  Make DateTimeView more robust to weird contexts.
  Make the RemoteViews context safe for Icons.
2015-07-31 03:23:50 +00:00
Dave Langemak
66cff122cc am 2e802cac: am 72dcb47d: am b880a036: am 02565c36: Merge changes from topic \'fix-notification-inflation-2\' into mnc-dev
* commit '2e802cac1dc036e62d6744d07d0cad56eb37052a':
  Make DateTimeView more robust to weird contexts.
  Make the RemoteViews context safe for Icons.
2015-07-31 03:18:01 +00:00
Dan Sandler
4b67713709 Make DateTimeView more robust to weird contexts.
In particular, some clients (*ahem* SystemUI) have been
known to inflate RemoteViews with unusual derived contexts
that may not have valid application contexts. DateTimeView
can now resist this.

Bug: 22852700
Change-Id: I5e91ae0e66859f5f5efd7b19c0ae6dfbc26bcc54
2015-07-30 22:33:12 -04:00
Dan Sandler
706274f7ff Make the RemoteViews context safe for Icons.
Icon needs the RemoteViews' internal context to reflect not
just the Resources of the originating application, but its
package name as well.

Bug: 22840771
Bug: 22852700
Change-Id: I1164cd38d99283982b00daadcf927c7cf63539b3
2015-07-30 22:32:54 -04:00
Alan Viverette
d46304cfd6 am 30a7a77f: am 38271527: am 82c14e68: am 92360585: am 559daf7a: Merge "Include non-zero dimension views in excess space calculation" into mnc-dev
* commit '30a7a77f7792f48ee635658b0de546c81503859d':
  Include non-zero dimension views in excess space calculation
2015-07-30 17:44:42 +00:00
Alan Viverette
30a7a77f77 am 38271527: am 82c14e68: am 92360585: am 559daf7a: Merge "Include non-zero dimension views in excess space calculation" into mnc-dev
* commit '382715273d962f2be27bb5948a61efbf234bfaba':
  Include non-zero dimension views in excess space calculation
2015-07-30 17:33:30 +00:00
Dan Sandler
ba36e0c2d1 am acb8f91d: am 936420a0: am 06e544f0: am a93ed128: am 7bd8e6a8: DateTimeView: don\'t assume you have an ApplicationContext.
* commit 'acb8f91d107c209d02f72166056b1480d8e00d68':
  DateTimeView: don't assume you have an ApplicationContext.
2015-07-30 17:19:19 +00:00
Dan Sandler
acb8f91d10 am 936420a0: am 06e544f0: am a93ed128: am 7bd8e6a8: DateTimeView: don\'t assume you have an ApplicationContext.
* commit '936420a06232dfc68a021b8fb407e423c6ac69a3':
  DateTimeView: don't assume you have an ApplicationContext.
2015-07-30 17:10:11 +00:00
Alan Viverette
559daf7a74 Merge "Include non-zero dimension views in excess space calculation" into mnc-dev 2015-07-30 17:02:45 +00:00
Dan Sandler
7bd8e6a8f2 DateTimeView: don't assume you have an ApplicationContext.
Bug: 22840771
Change-Id: I3be6369936f90e9ce4e61a59ea81b0d3408a0f99
2015-07-30 11:59:30 -04:00
Alan Viverette
da2f304409 Include non-zero dimension views in excess space calculation
Bug: 22840778
Change-Id: Iba44c59bbaa48f63b26f342e0510b4c421e8748b
2015-07-30 11:44:12 -04:00
Daniel Sandler
8515917246 am 202dd44a: am 5ea22216: am 82935916: am 033fe243: am bbe1682b: Merge changes from topic \'fix-media-notifications\' into mnc-dev
* commit '202dd44a90439eb823566b718c5a8fb159d73a73':
  Fully support Icons in Notification actions.
  Fix media notification action icons.
2015-07-30 04:05:19 +00:00