Commit Graph

5572 Commits

Author SHA1 Message Date
Alan Viverette
e71c6e3832 Merge "Constrain ListPopupWindow hint width spec to >= 0" into mnc-dev 2015-06-25 20:00:56 +00:00
Alan Viverette
ba4332d9cf Constrain ListPopupWindow hint width spec to >= 0
Bug: 22092169
Change-Id: Ia05302cf8d167aae26eccbf53dd3fd21d09b326d
2015-06-25 13:00:03 -07:00
Alan Viverette
fdf102e62d Merge "Constrain child width and height to >= 0 in FrameLayout.onMeasure()" into mnc-dev 2015-06-25 19:57:03 +00:00
Yohei Yukawa
ab142f7f57 Merge "Handle back key to cancel text action mode in full-screen IME." into mnc-dev 2015-06-25 19:39:36 +00:00
Alan Viverette
39fd902bdb Constrain child width and height to >= 0 in FrameLayout.onMeasure()
Bug: 22093669
Change-Id: I55e8a0289f871b73ed07f3d73e8297786f9acac1
2015-06-25 12:24:27 -07:00
Jun Mukai
46f087c43b Merge "Apply thumbTint and trackTint styles to Switch from xml." into mnc-dev 2015-06-25 18:16:57 +00:00
Alan Viverette
efb49bd811 Merge "Constrain width and height to >= 0 in FastScroller layout" into mnc-dev 2015-06-25 17:08:42 +00:00
Alan Viverette
de14ad55f6 Constrain width and height to >= 0 in FastScroller layout
Bug: 22071990
Change-Id: I9dcb2066ee069a3764b7d711cb341a4dfdc4445e
2015-06-25 09:57:30 -07:00
Mady Mellor
d4d802be39 Merge "Fix: Don't display the drag handles when focus is lost" into mnc-dev 2015-06-25 15:54:03 +00:00
Andrei Stingaceanu
3d7109a1f6 Merge "EditText - can not drag handles in extracted mode" into mnc-dev 2015-06-25 15:52:51 +00:00
Mady Mellor
a2861454aa Fix: Don't display the drag handles when focus is lost
The text selection handles should be hidden / shown when the window
loses / regains focus.

Additionally renames method to make more sense.

Bug: 22062480
Change-Id: I6e160234cf112ee285367637e2f1c14defd82e89
2015-06-25 08:40:27 -07:00
Andrei Stingaceanu
1cb1f1523a EditText - can not drag handles in extracted mode
In TextView's onPreDraw method, startSelectionActionMode()
is called, but the selection has already been started so
in startSelectionActionMode() it shows the
insertionController which hides the selectionController.
Fix this by adding a check to start the action mode only
if it is not already started.

Bug: 22028858
Change-Id: I2999423155b7a63a7d879bc8ea5032e17dff459f
2015-06-25 11:54:43 +01:00
Jun Mukai
9fb302cfbc Apply thumbTint and trackTint styles to Switch from xml.
Bug: 21664957
Change-Id: Id08ae89fb1586968df4b901816a8e108bb8570af
2015-06-24 18:31:06 -07:00
Alan Viverette
39310d3606 Avoid negative childSpecSize in RelativeLayout
Bug: 22071351
Change-Id: I951fd7c7973c49581d3ea30bae64d6c20bc362be
2015-06-24 17:03:48 -07:00
Alan Viverette
9bf9a3a99e Merge "Constrain FastScroller max width to be >= 0" into mnc-dev 2015-06-24 18:22:33 +00:00
Alan Viverette
c98922ba2f Constrain FastScroller max width to be >= 0
Bug: 22055552
Change-Id: Ib0bba93e5490ad9d8668c9532f23654a8cb702d9
2015-06-24 10:22:02 -07:00
Andrei Stingaceanu
2e5615467e Merge "Floating toolbar shown after rotation in extract mode" into mnc-dev 2015-06-24 09:16:36 +00:00
Yohei Yukawa
38940aab69 Handle back key to cancel text action mode in full-screen IME.
This CL is a follow up to I7998c8ee2162a0e01525a0cd66ec14fa505,
which completely removed ExtractActionMode including back key
handling in InputMethodService when full-screen mode is enabled.

It turns out that back key events still need to be handled in
InputMethodService when full-screen mode is enabled so that
users can still cancel floating text action mode with back key.

Bug: 22034992
Change-Id: I5f8db34f7425eef343d40d9820925ea6aaf9fccc
2015-06-24 00:20:24 -07:00
Dianne Hackborn
a6fb1e70ff Merge "Fix issue #20654534: API Review: android.app.assist" into mnc-dev 2015-06-23 19:33:04 +00:00
Keisuke Kuroyanagi
1384d1d900 Merge "Fix: TextView makes new layouts too frequently." into mnc-dev 2015-06-23 17:56:48 +00:00
Andrei Stingaceanu
8383072752 Floating toolbar shown after rotation in extract mode
Do not start the floating toolbar action mode and
do not show the handles if after a rotation when the
extract mode will be started. This fixes an issue where
onTouch after rotate duplicates the handles in extracted
mode.

Note: if NO_EXTRACT_UI flag is set then the toolbar,
selection and handles preserve their state.

Bug: 21960251
Change-Id: I1c7881bf2f40d8877fa0ce26e27a29398edc1296
2015-06-23 13:31:35 +01:00
Alan Viverette
ed0e11a93a Merge "Ensure child is attached before performing measure/layout in Spinner" into mnc-dev 2015-06-22 23:07:33 +00:00
Alan Viverette
aeaa396cae Merge "Revert "Revert "Work around inconsistent views in RelativeLayout.onMeasure()""" into mnc-dev 2015-06-22 22:38:09 +00:00
Alan Viverette
9554f9fc9e Revert "Revert "Work around inconsistent views in RelativeLayout.onMeasure()""
Turns out this was actually fine.

This reverts commit 9355533bf6.

Change-Id: I30c66fd423b569958244685098511d4ba08fbf37
2015-06-22 22:37:58 +00:00
Alan Viverette
25c6cd61d4 Ensure child is attached before performing measure/layout in Spinner
Bug: 21614663
Change-Id: Id84a720fac7050d312eb2eb6f12621217c4f8d0f
2015-06-22 15:25:55 -07:00
Dianne Hackborn
16036f2684 Fix issue #20654534: API Review: android.app.assist
Remove the old classes.

Change-Id: I949350cadc5fc304e2651d7db0ffd38e45db9b6e
2015-06-22 15:14:17 -07:00
Andrei Stingaceanu
b1891b3fc9 Fix selection by double tap in Extracted mode
Select with double tap in extracted mode has suffered
a regression recently: flickers and it does not correctly
select. Found this fix after a lot of trials.

Bug: 20128047
Change-Id: I1bbe8c11982d37e5409bac2b648a31b0ca1f0bbc
2015-06-22 12:42:06 +01:00
Vladislav Kaznacheev
8228e4247c Merge "Fix huge bounce-back in ListView when double-flinging" into mnc-dev 2015-06-22 09:30:20 +00:00
Doris Liu
4a79992591 Merge "Fix NumberPicker.setWrapSelectorWheel(boolean) not respecting user choice" into mnc-dev 2015-06-20 00:23:30 +00:00
Doris Liu
bcfdead943 Fix NumberPicker.setWrapSelectorWheel(boolean) not respecting user choice
The issue states that NumberPicker.setWrapSelectorWheel(false) only works
in a specific call order. The underlying problem is that NumberPicker
does not remember user's preference on whether the selector wheel should
be wrapped. Therefore, it only works when user sets their preference last,
after everything else that could affect the choice gets executed.

Bug: 19049714
Change-Id: Ic27d909cb3dd657993a4df9a04c819b6965ad11b
2015-06-19 16:33:39 -07:00
Alan Viverette
f3e8dca84b Merge "Create ListPopupWindow handler against main looper" into mnc-dev 2015-06-19 19:21: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
Vladislav Kaznacheev
160d12ee51 Fix huge bounce-back in ListView when double-flinging
The bounce-back reliably happened when AbsListView.fling
was called with high enough velocity (>50000). Such values
caused integer overflow when squared in the course of some
ballistic calculations in OverScroller.fitOnBounceCurve.

Bug: 19056278
Change-Id: I35d5376c67bc6847955b44ee268e89bce2db81d0
2015-06-19 11:22:59 +03:00
Keisuke Kuroyanagi
17b0bda4db Fix: TextView makes new layouts too frequently.
TextView#checkForRelayout was almost always called in
TextView#onRtlPropertiesChanged.
However, #onRtlPropertiesChanged just checks if re-layout
can be skipped for when the text has changed. As a result,
TextView makes new layouts too frequently in that method.

With this patch, TextView#checkForRelayout is called only
when mTextDir has actually changed.

Bug: 17971103
Change-Id: I449d8c8fd7370495cd5af9e38cada942744ca801
2015-06-19 15:24:07 +09: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
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
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
fe67c1ec6d Merge "Fix: Drag handle jumps between bidi boundaries." into mnc-dev 2015-06-18 03:43:44 +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
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
5ddaa72b9a Merge "Handle negative view types properly in getScrapView" into mnc-dev 2015-06-17 17:58:27 +00:00