Commit Graph

5638 Commits

Author SHA1 Message Date
Alan Viverette
3d63af9c4d am bbe35b32: am 0cadef68: am f3e8dca8: Merge "Create ListPopupWindow handler against main looper" into mnc-dev
* commit 'bbe35b32c2e1843d7d5f0ddde0063a4ead38a497':
  Create ListPopupWindow handler against main looper
2015-06-19 20:43:42 +00:00
Alan Viverette
f3e8dca84b Merge "Create ListPopupWindow handler against main looper" into mnc-dev 2015-06-19 19:21:11 +00:00
Alan Viverette
0204fd6a05 am 9e08cf8f: am 4e537151: am 7c669f45: Merge "Revert "Work around inconsistent views in RelativeLayout.onMeasure()"" into mnc-dev
* commit '9e08cf8f8f05a0da0777408ee8e940622df39e93':
  Revert "Work around inconsistent views in RelativeLayout.onMeasure()"
2015-06-19 18:56:11 +00:00
Alan Viverette
7c669f4547 Merge "Revert "Work around inconsistent views in RelativeLayout.onMeasure()"" into mnc-dev 2015-06-19 18:20:21 +00:00
Alan Viverette
9355533bf6 Revert "Work around inconsistent views in RelativeLayout.onMeasure()"
This reverts commit 3e2e064a1f.

Change-Id: Ib3712076585cba507ef1666e3fb6abb2bedb016f
2015-06-19 18:19:56 +00:00
Dan Sandler
2983f6ee42 am 2a0cc6cf: am 7a7e8fc8: am 11859eba: Merge "Announce chronometers with time-unit words." into mnc-dev
* commit '2a0cc6cf4dc61e03d5bb5348177cca95aeb0257d':
  Announce chronometers with time-unit words.
2015-06-19 14:17:45 +00:00
Dan Sandler
11859eba4e Merge "Announce chronometers with time-unit words." into mnc-dev 2015-06-19 00:50:59 +00:00
Alan Viverette
4a50723fe3 Create ListPopupWindow handler against main looper
Required for CTS tests.

Bug: 21664698
Change-Id: Id33c672d7d50a2162c519249bbbf5b8081faf830
2015-06-18 17:11:19 -07:00
Mady Mellor
06b9ede565 am 5765561f: am a0993670: am 03709c78: Merge "Text selection: update touch delta when moving towards handles" into mnc-dev
* commit '5765561fa63e102721ef845767543859a28e9d1a':
  Text selection: update touch delta when moving towards handles
2015-06-18 17:57:56 +00:00
Adam Powell
ed213cfea3 am 0f6dd549: am 7fd90265: am 2a1f9164: Merge "Un-hide ViewGroup#onViewAdded/onViewRemoved" into mnc-dev
* commit '0f6dd54943f3b343406c655d3efc392ede0cf0ea':
  Un-hide ViewGroup#onViewAdded/onViewRemoved
2015-06-18 17:57:51 +00:00
Mady Mellor
03709c780a Merge "Text selection: update touch delta when moving towards handles" into mnc-dev 2015-06-18 17:26:04 +00:00
Adam Powell
2a1f916418 Merge "Un-hide ViewGroup#onViewAdded/onViewRemoved" into mnc-dev 2015-06-18 17:20:44 +00:00
Adam Powell
6690d018b9 Un-hide ViewGroup#onViewAdded/onViewRemoved
These methods are generally useful for writing custom views, and by
exposing them we make it easier for custom view authors to still allow
app developers to use an OnHierarchyChangedListener since it will not
be occupied by a custom view's implementation.

Also move the actual dispatch to package-scoped dispatch methods so
that a developer forgetting to call super won't stop a listener from
functioning.

Bug 21866523

Change-Id: Ie2bb5e241d7c5a02a5033f33ecdaeb40aceb20b5
2015-06-18 10:19:18 -07:00
Mady Mellor
2b48782e36 am fd597de3: am 0bbabc03: am 9a08fe2a: Merge "Update button press in AbsListView to use new MotionEvent APIs" into mnc-dev
* commit 'fd597de38eb4477846be8046e96b2ab7cc68d183':
  Update button press in AbsListView to use new MotionEvent APIs
2015-06-18 16:19:40 +00:00
Mady Mellor
9a08fe2aca Merge "Update button press in AbsListView to use new MotionEvent APIs" into mnc-dev 2015-06-18 15:46:27 +00:00
Keisuke Kuroyanagi
12b92e57eb am 4e0ff9c1: am 3e43afed: am fe67c1ec: Merge "Fix: Drag handle jumps between bidi boundaries." into mnc-dev
* commit '4e0ff9c124315a9dfbf987136f933a6e433c63f9':
  Fix: Drag handle jumps between bidi boundaries.
2015-06-18 04:25:33 +00:00
Keisuke Kuroyanagi
fe67c1ec6d Merge "Fix: Drag handle jumps between bidi boundaries." into mnc-dev 2015-06-18 03:43:44 +00:00
Chet Haase
9dff88c9d1 am 7751e2dc: am 2139e92c: am 45bb0ca4: Merge "ImageView updates cached drawable dimensions when drawable updates" into mnc-dev
* commit '7751e2dc96c81035cb57cc69e86ba0762da71ce2':
  ImageView updates cached drawable dimensions when drawable updates
2015-06-17 23:41:23 +00:00
Raph Levien
d5a0e5c84b am fc40d939: am efe1f4bb: am 8872ca4d: Merge "Remove indents from TextView" into mnc-dev
* commit 'fc40d939819dca79cd02b7be93531cf2268bb9fa':
  Remove indents from TextView
2015-06-17 23:41:15 +00:00
Alan Viverette
f8e35e9af6 am d496d3bd: am 5e034226: am e1c94726: Merge "Work around inconsistent views in RelativeLayout.onMeasure()" into mnc-dev
* commit 'd496d3bd061695240036e041f657794a0f054bfa':
  Work around inconsistent views in RelativeLayout.onMeasure()
2015-06-17 23:26:59 +00:00
Chet Haase
45bb0ca49a Merge "ImageView updates cached drawable dimensions when drawable updates" into mnc-dev 2015-06-17 23:07:17 +00:00
Raph Levien
8872ca4d55 Merge "Remove indents from TextView" into mnc-dev 2015-06-17 23:06:17 +00:00
Raph Levien
8edac58e55 Remove indents from TextView
On more careful reflection, the "indents" feature was not ready for
inclusion in the public API. It is still available at a lower level
in StaticLayout.

Also fix a minor typo in the doc for breakStrategy.

Bug: 20641996
Change-Id: I5cd976a536c48615980860396b1564b51b19e14a
2015-06-17 15:53:33 -07:00
Chet Haase
8473f5a768 ImageView updates cached drawable dimensions when drawable updates
Changes to drawable dimensions were not propagated to cached dimension
values in ImageView. Now this is done when the drawable is invalidated.

Issue #18798152  ImageView caches wrong value of mDrawableWidth and mDrawableHeight

Change-Id: I8da7d82b0543fa02d8ef3d896595bd0e5ea2a61e
2015-06-17 15:28:25 -07:00
Alan Viverette
e1c947263f Merge "Work around inconsistent views in RelativeLayout.onMeasure()" into mnc-dev 2015-06-17 22:10:11 +00:00
Adam Powell
5407bdcc34 am c0611fd7: am fb1fdca9: am 074c3404: Merge "Add matching xml attributes for existing Toolbar properties" into mnc-dev
* commit 'c0611fd77e27addfdef8a2b870328b4985d28b91':
  Add matching xml attributes for existing Toolbar properties
2015-06-17 21:03:52 +00:00
Alan Viverette
3e2e064a1f Work around inconsistent views in RelativeLayout.onMeasure()
Previously, RelativeLayout's measure pass could crash if the view's
children were modified without calling requestLayout() prior to the
next measure pass. This avoids the issue by only looking at the most
recent set of sorted views and preserves the previous behavior where
onMeasure() could return incorrect data.

Bug: 21123292
Change-Id: If471d071d1d2e2729cf13854d95b1f517c1fe73a
2015-06-17 13:42:32 -07:00
Adam Powell
074c340420 Merge "Add matching xml attributes for existing Toolbar properties" into mnc-dev 2015-06-17 20:22:37 +00:00
Yigit Boyar
8c184d3d51 am f8acc3af: am b2b53fb9: am 5ddaa72b: Merge "Handle negative view types properly in getScrapView" into mnc-dev
* commit 'f8acc3af12add21e64acd7a744234fe3f65c6096':
  Handle negative view types properly in getScrapView
2015-06-17 18:33:48 +00:00
Mady Mellor
b5884ca1c0 am 4a392886: am 31fa5ad3: am 5279d11f: Merge "Drag to select text: add some slop for moving between lines" into mnc-dev
* commit '4a39288618c3601fea0e176561ca9f6ee2a02163':
  Drag to select text: add some slop for moving between lines
2015-06-17 18:12:32 +00:00
Yigit Boyar
5ddaa72b9a Merge "Handle negative view types properly in getScrapView" into mnc-dev 2015-06-17 17:58:27 +00:00
Mady Mellor
ae7bc168ed am 432e0422: am ef25faa0: am f0522882: Merge "Insertion cursor: add some slop for moving between lines" into mnc-dev
* commit '432e0422ca8b85010bc489868ce34adabb02da0b':
  Insertion cursor: add some slop for moving between lines
2015-06-17 17:39:23 +00:00
Mady Mellor
5279d11f25 Merge "Drag to select text: add some slop for moving between lines" into mnc-dev 2015-06-17 17:36:31 +00:00
Mady Mellor
c1b73d9ea1 am 2663f817: am 7b914149: am 13e54ff0: Merge "Text selection: add some slop for moving between lines" into mnc-dev
* commit '2663f817c784fa5e07dd0c5ab401c12b4c296873':
  Text selection: add some slop for moving between lines
2015-06-17 17:07:57 +00:00
Mady Mellor
ee3821e565 Insertion cursor: add some slop for moving between lines
Applying same method to insertion cursor as the text selection drag
handles to improve moving along lines.

Basically adds some slop above / below the current line and only
allows you to change lines if you move outside of that.

Bug: 21306433
Change-Id: I6c7f3a496fbd1ea66936832f96325736cea872aa
2015-06-17 09:48:38 -07:00
Mady Mellor
f9f8aebdc6 Drag to select text: add some slop for moving between lines
It's pretty easy to accidentally move to a different line when
selecting text. This CL makes an adjustment so that if the user
is on a line, they must move above the top of it + slop to move
up a line, and they must move below the bottom of it + slop to move
down a line. This applies the changes to the drag accelerator.

This CL also makes an adjustment to not apply the finger offset
to the drag accelerator until the user has moved lines, this was
causing an issue where it would immediately include the above line
when initiating the selection.

Bug: 21306433
Bug: 21303943
Change-Id: Id240136493f62524fe6445d8bd65479084fe8126
2015-06-17 09:46:01 -07:00
Mady Mellor
cc65c37f10 Text selection: add some slop for moving between lines
It's pretty easy to accidentally move to a different line when
selecting text. This CL makes an adjustment so that if the user
is on a line, they must move above the top of it + slop to move
up a line, and they must move below the bottom of it + slop to move
down a line.

This CL also makes a small modification to check if the layout is
null and return early which simplifies some of the following code.

Bug: 21306433
Change-Id: I4a854e644faafaf1e159201ae1f2838862f16b25
2015-06-17 09:25:19 -07:00
Mady Mellor
0d85d2af94 Update button press in AbsListView to use new MotionEvent APIs
Button press events now occur in onGenericMotionEvent rather than
onTouch event, this alters the code to listen in onGenericMotionEvent.

Bug: 21148238
Change-Id: Idfbd61683f40a25964c14ec26b71042657e2aaeb
2015-06-16 17:08:27 -07:00
Adam Powell
6b3fc9a903 Add matching xml attributes for existing Toolbar properties
Bug 21010256

Change-Id: I3ac9491d86dd502f7572e37a3c9b70ffb8957ced
2015-06-16 15:47:52 -07:00
Adam Powell
eee619b417 am 3d501550: am d5965799: am 8edfe18c: Merge "Fully remove Toolbar children when action views expand" into mnc-dev
* commit '3d501550ae25564240af2a7bb777cafab19157ea':
  Fully remove Toolbar children when action views expand
2015-06-16 22:17:28 +00:00
Abodunrinwa Toki
bb6ccf9714 am a9eee504: am 03c70cac: am 98f98dd1: Merge "Fix floating toolbar flickers." into mnc-dev
* commit 'a9eee50455ff3894a17273fa1ffac2700cfa0d4c':
  Fix floating toolbar flickers.
2015-06-16 22:03:52 +00:00
Adam Powell
8edfe18c19 Merge "Fully remove Toolbar children when action views expand" into mnc-dev 2015-06-16 21:30:13 +00:00
Abodunrinwa Toki
f444b5c3ae Fix floating toolbar flickers.
-Flicker was a side effect the delay in hiding the toolbar when
there is a down press on a TextView handle. The timing clashed
with the time it takes for the FloatingActionMode to release a
hide lock on a changing content rect. Extra flickers also happened
if the ActionMode happened to be invalidated at about the same time.
Since there was no longer a hide lock, the toolbar refreshed, getting
rid of the "Select all" menu item.
FIX. I believe we don't need the delayed hide on down press on a
TextView handle. I've removed this.

-I've also updated FloatingActionMode to ensure that hide locks
overlap one another if necessary. The toolbar can only be visible if
all locks are off.

Bug: 21793687
Change-Id: I290ea45ab17d5862b453cb319afb4c8ffe084cd0
2015-06-16 15:47:04 +01:00
Yigit Boyar
f85e673980 Handle negative view types properly in getScrapView
ListView had a bug where it would pass wrong view to
the adapter if adapter is using HEADER or IGNORE types
for views.

This CL fixes that issue and ensures that ListView
will not try to search scrap view lists for these
views which are never recycled.

Bug: 19409057
Change-Id: I2653bbca93fbaf48567b47d10f273c8921d59bd2
2015-06-16 02:40:24 +00:00
Adam Powell
5f6228454d Fully remove Toolbar children when action views expand
The previous implementation of toggling visibility resulted
developer-set child visibility getting stomped. Fully detach child
views that shouldn't be shown instead. This is more consistent with
the coming and going of other system child views.

Bug 18156260

Change-Id: I8469d45eeb950dc0232f703efe8401233241c657
2015-06-15 14:33:45 -07:00
Dianne Hackborn
f8b3253180 am ccd6d0c1: am d55860d9: am 8a435ced: Merge "Fix APIs." into mnc-dev
* commit 'ccd6d0c14decd111e7e12bf9844fa5ff75aa912e':
  Fix APIs.
2015-06-12 17:48:22 +00:00
Dianne Hackborn
8a435ced67 Merge "Fix APIs." into mnc-dev 2015-06-12 16:34:38 +00:00
Keisuke Kuroyanagi
a05a68d97e am 60a640f4: am 3015edb0: am a31940df: Merge "Reset drag accelerator state in Editor#sendOnTextChanged." into mnc-dev
* commit '60a640f4152bb1587f0332d9188c884ceddabb3b':
  Reset drag accelerator state in Editor#sendOnTextChanged.
2015-06-12 11:43:17 +00:00
Keisuke Kuroyanagi
a31940df17 Merge "Reset drag accelerator state in Editor#sendOnTextChanged." into mnc-dev 2015-06-12 11:10:20 +00:00
Adam Powell
b94e938e50 am 0b8f8c78: am b0fb6255: am de64ac45: Merge "Check targetSdkVersion when passing size hints for UNSPECIFIED specs" into mnc-dev
* commit '0b8f8c78a250b252e7c5b06c5f1f404e33791ff0':
  Check targetSdkVersion when passing size hints for UNSPECIFIED specs
2015-06-12 01:37:01 +00:00