Commit Graph

5349 Commits

Author SHA1 Message Date
Alan Viverette
f71c93ff9a am aeedef55: am da0d6a6b: Merge "Correctly handle intercepted touch events in FastScroller" into mnc-dev
* commit 'aeedef552d64027d7de40d4cc13c182f97250b6e':
  Correctly handle intercepted touch events in FastScroller
2015-05-01 18:48:46 +00:00
Yohei Yukawa
784480b62c am 71cbadf3: am 097d5f10: Merge "Suggestions popup must be dismissed before device rotation." into mnc-dev
* commit '71cbadf3971c67a839d91c6685ba88c9b938b1ce':
  Suggestions popup must be dismissed before device rotation.
2015-05-01 18:48:20 +00:00
Alan Viverette
da0d6a6b8a Merge "Correctly handle intercepted touch events in FastScroller" into mnc-dev 2015-05-01 18:30:26 +00:00
Alan Viverette
fb99ba895e Correctly handle intercepted touch events in FastScroller
Previously we'd return true from onIntercept and assume the DOWN event
was handled, then onTouch would return false and the host view would
receive the DOWN event. Now we consume the event in onTouch.

Bug: 19080751
Change-Id: I1bd35b4c25a0760f4248ade443d09b8ca4b71e7c
2015-05-01 10:10:15 -07:00
Yohei Yukawa
85d08f1bf8 Suggestions popup must be dismissed before device rotation.
This is a follow up CL for Ia515fc576ddf2127b2f9863cc2652aeb619fff6e
for Bug 5420741, which had basically the same goal to Bug 20158984.

The goal here is to dismiss any popup window opened by the TextView
when the device is about to be rotated.  This is important because
Window Manager and Input Method Manager Service are really sensitive
about which window is focused before and after the device is rotated.

In Ia515fc576ddf2127b2f9863cc2652aeb619fff6e, we tried to distinguish
two kinds of focus-lost. One is the true focus lost where suggestions
pop-up (if any) should be dismissed, and the other is an side effect
of showing the suggestions pop-up itself. We have used isShowingUp()
to distinguish distinguish one from the other. In short, it
indicates whether onWindowFocusChanged() is not called yet or is
called at least once.

In extract edit mode, however, it turned out that
onWindowFocusChanged() is never called (at least in recent builds).
As a result, the popup window is not dismissed when it should be.
One of the smallest solution would checking isShowingUp() only when
the target TextView is not ExtractEditText.

Adding unit test would be handled as Issue #20703391.

BUG: 5420741
BUG: 20158984
BUG: 20703391
Change-Id: I1706cf2ea0b0bdfe8894ab57fc3caa8ff12d8aab
2015-04-30 17:22:28 -07:00
Alan Viverette
68999a740c am 19b9f8ef: am 8310f87d: Merge "ActionBar SearchView\'s default hint shouldn\'t override SearchableInfo" into mnc-dev
* commit '19b9f8ef3eaf392db0a993ae0d5a7a84e9d6c60f':
  ActionBar SearchView's default hint shouldn't override SearchableInfo
2015-04-30 16:21:57 +00:00
Alan Viverette
8310f87d96 Merge "ActionBar SearchView's default hint shouldn't override SearchableInfo" into mnc-dev 2015-04-30 15:59:21 +00:00
Alan Viverette
b4004dfc84 ActionBar SearchView's default hint shouldn't override SearchableInfo
Moves the queryHint to defaultQueryHint, specifies the override order
as queryHint > SearchableInfo > defaultQueryHint.

Cleans up annotations and comments for several related methods.

Bug: 20614122
Change-Id: Ib58ec309e6814cd512df147d789ec0cd546018af
2015-04-29 16:55:42 -07:00
Abodunrinwa Toki
8020631fa4 am 45b04c1a: am 47ea8b3d: Merge "DO NOT MERGE: Update floatingtoolbar position when cursor moves." into mnc-dev
* commit '45b04c1a5ef4f21b14b40dd0c1035933188da322':
  DO NOT MERGE: Update floatingtoolbar position when cursor moves.
2015-04-29 17:43:40 +00:00
Abodunrinwa Toki
47ea8b3d6b Merge "DO NOT MERGE: Update floatingtoolbar position when cursor moves." into mnc-dev 2015-04-29 17:26:29 +00:00
Andrei Stingaceanu
da8d35cd31 am 78a4348a: am eea5a9e0: Merge "DO NOT MERGE - Minor clean up: redundant functionality in Editor and TextView." into mnc-dev
* commit '78a4348a535e530ae77c0e7777247d495596be7c':
  DO NOT MERGE - Minor clean up: redundant functionality in Editor and TextView.
2015-04-29 16:47:25 +00:00
Andrei Stingaceanu
eea5a9e0de Merge "DO NOT MERGE - Minor clean up: redundant functionality in Editor and TextView." into mnc-dev 2015-04-29 16:21:16 +00:00
Alan Viverette
9c36ee9b4f am 2ddfcc4a: Merge "Context leaks in EditText causes out of memory"
* commit '2ddfcc4ade5d6db69808a340ae54280872559ec1':
  Context leaks in EditText causes out of memory
2015-04-29 04:54:28 +00:00
Alan Viverette
2ddfcc4ade Merge "Context leaks in EditText causes out of memory" 2015-04-29 04:19:40 +00:00
Alan Viverette
8f021114b1 am 837bf24e: am e861c8eb: Merge "Fix DatePicker max date, disabled day color, and arrow visibility" into mnc-dev
* commit '837bf24ee4c44d344f6fc5959c758bf3c287e8b3':
  Fix DatePicker max date, disabled day color, and arrow visibility
2015-04-29 02:00:31 +00:00
Chris Craik
e01d4b3566 am 4f66e48d: am 2f1d09c3: Merge "Use default constructor to get anti-aliasing" into mnc-dev
* commit '4f66e48de3a66ca41916b897f0898f8eb23aa2ac':
  Use default constructor to get anti-aliasing
2015-04-29 01:59:11 +00:00
Chris Craik
4527289b76 am 0e7d1432: am ff623a5a: Merge "Remove unused flags and dirty rects" into mnc-dev
* commit '0e7d1432d4ef5662c4aa7e89adf3f43a8761f4bd':
  Remove unused flags and dirty rects
2015-04-29 01:59:03 +00:00
Alan Viverette
e861c8eb63 Merge "Fix DatePicker max date, disabled day color, and arrow visibility" into mnc-dev 2015-04-28 23:39:23 +00:00
Chris Craik
2f1d09c3c5 Merge "Use default constructor to get anti-aliasing" into mnc-dev 2015-04-28 22:06:17 +00:00
Alan Viverette
5c33949d02 Fix DatePicker max date, disabled day color, and arrow visibility
Day validation moved from the PagerAdapter to the DayPickerView,
which is widget that actually handles the touch interaction and
disabled state for individual days.

Fixed disabled states for primary and secondary activated text
colors. Replaced old light/dark color state lists with themed
versions.

Removed conflicting view visibility changes for managing next and
previous arrows in DayPickerView.

Bug: 20630417
Bug: 20641013
Bug: 20641879
Change-Id: Icdaf02a3b57ec162169c31b8a27ebea908552321
2015-04-28 14:07:36 -07:00
Chris Craik
58fc522a69 Use default constructor to get anti-aliasing
Change-Id: I3e078a3bc91a2fd703984ba18b5e7e98069b32f1
2015-04-28 11:49:27 -07:00
Alan Viverette
5b276f1c03 am 6af08c6b: Merge "Fix for infinite loop in RemoteViewsAdapter"
* commit '6af08c6b7693b4329184c9cccbc474a0b6a9ea5c':
  Fix for infinite loop in RemoteViewsAdapter
2015-04-28 17:40:05 +00:00
Alan Viverette
6af08c6b76 Merge "Fix for infinite loop in RemoteViewsAdapter" 2015-04-28 17:10:41 +00:00
Abodunrinwa Toki
bcdf0ab13d DO NOT MERGE: Update floatingtoolbar position when cursor moves.
NOTE: This is only done on ACTION_UP event since the toolbar is
going to be hidden while one is dragging the handles.

Change-Id: Id09fc076edb0117ebceb26395ac91ee4d2283c2d
2015-04-28 17:46:17 +01:00
Andrei Stingaceanu
47f82ae811 DO NOT MERGE - Minor clean up: redundant functionality in Editor and TextView.
This is a no-op.

Change-Id: I28ec363a256d3d1a94e378d428897cc67c77d578
2015-04-28 17:43:54 +01:00
Chris Craik
956f340aac Remove unused flags and dirty rects
bug:17209071

Also update DisplayList->RenderNode naming in Editor

Change-Id: I1d505640ba7388a0b0042d9c787f859e45a24da5
2015-04-28 09:40:01 -07:00
Keisuke Kuroyanagi
d2b9bd80a2 Merge "Fix: End handle disappears when the selection is short." into mnc-dev 2015-04-28 04:58:45 +00:00
Robert Shih
39dbbd93e4 MediaController: workaround to disable seek
An example use case is live HLS streams.

Bug:19489473
Change-Id: I9c278f2875a5faaf1af092cc84888d4280a00747
2015-04-27 14:42:22 -07:00
Keisuke Kuroyanagi
28b5b14449 Fix: Selection handles are wrongly shown.
Selection handles were always shown when selection action
mode is started at first time. When the action mode is
started without a selection, only insertion handle must be
shown.

Bug: 20264980
Bug: 20407551

Change-Id: I630804e007f795d28f87e3fa6cba0de5bf588c78
2015-04-27 09:48:26 +00:00
Keisuke Kuroyanagi
6cda1e28e3 Fix: End handle disappears when the selection is short.
HandleView#isVisible didn't use getHorizontalOffset; thus,
the position is always computed as if Gravity.LEFT is set.
As a result, isVisible can be wrongly false for the end
handle and the handle is dismissed.

Bug: 20480054
Change-Id: Ib3242000bb98ae28e0cb37bf5b05069754abbfc6
2015-04-27 09:45:06 +00:00
Adam Cohen
daa58a4008 Merge "Remove problematic early return from notifyDataSetChanged" 2015-04-24 23:43:57 +00:00
Adam Cohen
005f7cf13e Remove problematic early return from notifyDataSetChanged
-> If connection to the service fails for whatever reason,
mNotifyDataSetChangedAfterOnServiceConnected can get stuck to true, preventing
future connections to the service. Don't let this prevent from connecting to the
service.

issue 19890339

Change-Id: I376101ae146359109df53add3a3202ba2e1e842d
2015-04-24 16:23:42 -07:00
Wale Ogunwale
e31788e12b Merge "Remove ZoomButtonsController view immediately when !visible" 2015-04-24 20:47:26 +00:00
Wale Ogunwale
5e641d6536 Remove ZoomButtonsController view immediately when !visible
When an acitvity with ZoomButtonsController is destorying all
its views are removed immediately except for the
ZoomButtonController view which is deferred. This causing the
system to think the window was leaked at the end of the current
clean-up pass since the view is still around. We now remove
the view immediately when setVisible(false) is called which is
the current signal that the window is detaching or the parent
view is now hidden.

Bug: 18280446
Change-Id: If566b402c2914a72539e28e4f6d768c6199f2d2f
2015-04-24 13:46:11 -07:00
Alan Viverette
d4925af839 Merge "Change direction of DPAD_LEFT and DPAD_RIGHT if LayoutDirection is RTL" 2015-04-24 19:40:58 +00:00
Jorn Jacobsson
599b64f937 Change direction of DPAD_LEFT and DPAD_RIGHT if LayoutDirection is RTL
Changes the behaviour of onKeyDown for DPAD_LEFT/RIGHT when the
layoutDirection is RTL, to move the focus in the correct direction.

Change-Id: I889649788d1e6f347aed90d6683d9f4dd6807da0
2015-04-24 12:34:50 -07:00
Alan Viverette
6e37e5a006 Merge "Implement RTL support in framework ViewPager, DatePicker" 2015-04-24 18:06:50 +00:00
Keisuke Kuroyanagi
0591651a62 Quit showing "SELECT ALL" for inappropriate fields.
This blocks showing "SELECT ALL" in FloatingToolBar when
the input is empty or the field is a password field.

Bug: 20407551
Change-Id: Ia25700bbee4f78445776af46eb1369af6600d946
2015-04-24 19:10:50 +09:00
Abodunrinwa Toki
56195db6c4 TextView: Invalidate ActionMode content rect on scroll.
Bug: 20470464
Change-Id: I1a9178903db00d1cef5a835d055939b2ce138290
2015-04-23 19:10:54 +00:00
Andrei Stingaceanu
e72e94767c Merge "Introduce "Share" option to the floating text selection toolbar." 2015-04-23 09:15:07 +00:00
Keisuke Kuroyanagi
08f7fd4d79 Fix: Wrong condition to detect selection shrink.
In the old logic, vertical selection shrink is detected
when the offset decreases and line number of the end handle
position increases. This never happens.

Bug: 20482453
Change-Id: I9e51742fcab4abe939f72130c51be773818aec62
2015-04-23 14:33:07 +09:00
Alan Viverette
ddf655c49f Implement RTL support in framework ViewPager, DatePicker
Lays out ViewPager in the opposite direction when in RTL mode, e.g.
the first item's starting edge is laid out at the largest possible
scrolling distance. This preserves both the meaning of positive
scrollX values and the meaning of positive adapter positions.

Also removes clickable attribute from DayPickerView since it has a
virtual view hierarchy.

Bug: 19408740
Bug: 20134073
Change-Id: Ib6f945335bd88da59c8c593c7c270e290e15d0a5
2015-04-22 13:43:31 -07:00
Andrei Stingaceanu
c649dae8e0 Merge "Cleanup unused icons on the floating toolbar." 2015-04-22 09:25:31 +00:00
Keisuke Kuroyanagi
05fd8d50b2 Stop showing "Replace" when selection isn't inside spans.
Currently, "Replace" is shown when any spans intersects
the selection. It causes confusing behavior when multiple
words are selected. "Replace" is in the ActionBar, but it's
unclear which word will be replaced. It can happen when
text is selected using long tap + drag, unig keyboard, or
using a mouse.

Bug: 19396964
Change-Id: I512f5f566d4060cd0aa7b28594054bf4f6bf7458
2015-04-22 15:33:27 +09:00
Andrei Stingaceanu
fbafc78648 Cleanup unused icons on the floating toolbar.
Floating toolbars move to a text based actionMode.

Bug: 20212703
Change-Id: Id94599487c2c70712f20d7044cd7ba1248813945
2015-04-21 11:55:47 +01:00
Andrei Stingaceanu
7f0c5bd543 Introduce "Share" option to the floating text selection toolbar.
Change-Id: I04b564224847eeb4e5f2a61f6a41f6046a1969a1
2015-04-21 11:34:15 +01:00
Alan Viverette
33f0c93fa9 Merge "Update the popup reveal animation to more closely match window reveal" 2015-04-21 00:29:36 +00:00
Andrei Stingaceanu
6154b0909c Text processing - stop showing an empty toast.
If the text processing app returns empty or null text don't show the toast.

Bug: 20326103
Change-Id: Ib8534b851d2046fe7c17f674f170f9630e4a364d
2015-04-20 15:03:55 +01:00
Alan Viverette
65aea84c5a Merge "Move date picker arrows out of SimpleMonthView" 2015-04-17 18:16:19 +00:00
Alan Viverette
78bf1d329a Move date picker arrows out of SimpleMonthView
Also fixes incorrect docs in Drawable.

Bug: 20188255
Change-Id: I01c8563f734d9c1dad1e149bee80c651981e469f
2015-04-17 10:39:22 -07:00