Commit Graph

1614 Commits

Author SHA1 Message Date
Gilles Debunne
b7012e841c Removed ViewTreeObserver in TextView when handles are hidden
terminate method is no longer needed since handles are popupWindow
which have their own fade-out animations.

Change-Id: I8354f78ece2ffe9c098ef2f02f0d637fc4c813c0
2011-02-25 11:00:11 -08:00
Svetoslav Ganov
30b1fe07a7 Merge "Exposing the CalendarView of the DatePicker." 2011-02-24 16:48:38 -08:00
Svetoslav Ganov
d5623fab34 Merge "The NumberPicker input cotrols are somtimes not shown." 2011-02-24 16:48:26 -08:00
Svetoslav Ganov
5f3f6ce154 Exposing the CalendarView of the DatePicker.
bug:3272194

1. Added a getter to DatePicker.

Change-Id: If0c7fee4ab5f6abf6b12a02dbd5d519c00683115
2011-02-24 15:36:19 -08:00
Svetoslav Ganov
f66adbe756 The NumberPicker input cotrols are somtimes not shown.
bug:3452868

1. Now hiding the input controls, which also cancels the input controls
   fade-in animation, on every intercept of down since the fade-in
   anumation flips a flag used to guide the drawing of the input controls.
   Note that we also want the scroll wheel shown on down but the fade-in
   anumation is actually hiding it upon completion.

Change-Id: Ib161ed757e537365b21e6913370d264152dca1fe
2011-02-24 15:08:43 -08:00
Gilles Debunne
808b04abe6 Merge "Cursors correctly displayed with legacy theme." 2011-02-24 10:29:44 -08:00
Gilles Debunne
eca97a320f Cursors correctly displayed with legacy theme.
Bug 3482848

Change-Id: Ic2eda961a8bb5e865bc638106124d00a5a7b4b21
2011-02-23 18:06:48 -08:00
Gilles Debunne
ddf00b8afe Text handles movement improvements.
Bug 3329346

Making sure the cursor is never hidden by the finger. Some
vertical movement is not repercuted on the handles' position
if it moves the finger closer to its 'ideal' touch position,
where both the insertion line and the top of the handle are
visible.

Also removed the hysteresis line filter which is not that
usefull and feels sluggy.

Change-Id: I6ad0fed0cf66753c6571b3bc620b1a0f2397c7b2
2011-02-23 17:25:13 -08:00
Romain Guy
557704e22a Merge "A bit more doc for ListAdapter#areAllItemsEnabled()." 2011-02-23 16:04:07 -08:00
Romain Guy
68b6b1c2d1 A bit more doc for ListAdapter#areAllItemsEnabled().
Change-Id: I339de99f52a8b5a3405d2aabd83a6dc92ca96e98
2011-02-23 16:05:07 -08:00
Romain Guy
e42aa50ded am e5410aa1: am ad492161: am a2090bea: am 7118bdec: Merge "Fix for #12945: ProgressBar.setMax() will always redraw."
* commit 'e5410aa165d2c707c9f31eabbfcf9c2332d9228a':
  Fix for #12945: ProgressBar.setMax() will always redraw.
2011-02-22 21:35:20 -08:00
Gilles Debunne
81f08086b4 Text selection handles correctly scroll
Bug 3416154

The origin of the problem is new display optimisations that enable
a scrollView to be scrolled without calling the onDraw method of its
children. As a result, the handles' positions were not updated on scroll.

DropDown popup menu have an integrated scroll listener that will fix the
problem. Using these indead is the first part of the solution.

The next problem is that when they get hidden, these popups try to move their
parent (the TextView in our case) which creates a scroll conflict. Fixed by
overriding findDropDownPosition.

Finally, when the handles get invisible, a new scroll listener has to be
installed that will show them back in case the view is scrolled back.

This is also an important step to fix Bug 3441308 (selectable text in list
views).

Debugging find outs:
Small optimization in PopupWindow to avoir unregistering then registering
back the listener when it is updated.

getHandle().show(); is not needed since updatePosition will do it through
moveTo().

Change-Id: I6bf6a3649538328257734ed1e651b23b889d65d9
2011-02-22 15:21:17 -08:00
Romain Guy
e5410aa165 am ad492161: am a2090bea: am 7118bdec: Merge "Fix for #12945: ProgressBar.setMax() will always redraw."
* commit 'ad492161e4384efe11daec60cd14902f6b2c662a':
  Fix for #12945: ProgressBar.setMax() will always redraw.
2011-02-22 14:48:21 -08:00
Gilles Debunne
76327dc0a8 Merge "Tuning the touch up filter." 2011-02-22 13:59:20 -08:00
Gilles Debunne
8eb18b114e Merge "Fixes around cursor blink." 2011-02-22 13:57:14 -08:00
Gilles Debunne
0c4650b4d5 Merge "Cursor does not jump back to its previous position when IME is showed up." 2011-02-22 13:57:00 -08:00
Romain Guy
2b9f895b02 Merge "Add documentation to GridView." 2011-02-22 11:13:29 -08:00
Romain Guy
84c6b95a77 Add documentation to GridView.
Change-Id: Ic81e498ad05f0c9c33580ecd6ce895ff1b6e00c4
2011-02-22 11:15:42 -08:00
Gilles Debunne
bc7a4c8cfa Tuning the touch up filter.
Bug 3436027

A movement has to happen recently, and there has to have been a stable
period before this.

Also fixes a problem with the paste popup that could be displayed for very
fast motion since it was only based on time and not on distance.

Change-Id: I02264b4d54e4d1323ebc2d1b5102769ba2d8569a
2011-02-18 14:56:06 -08:00
Gilles Debunne
3d01006fd6 Fixes around cursor blink.
Bug 3394800

A previous fix called cancel when the window was detached. The cancel/uncancel
mechanism does not actually removes the Blink runnable.

It is indeed more a suspend, which is used when the window loses focus.
The problem here was that uncancel was never called.

Removing the runnable callback instead.

Also rationalized the use of makeBlink and the setting of mShowCursor

Change-Id: I92aac43a891991b7cc98738de0f12332ab16907a
2011-02-18 14:50:52 -08:00
Romain Guy
a2090bea48 am 7118bdec: Merge "Fix for #12945: ProgressBar.setMax() will always redraw."
* commit '7118bdec523568842e70555e353951df9f2596fd':
  Fix for #12945: ProgressBar.setMax() will always redraw.
2011-02-18 07:53:50 -08:00
Michael Krehan
58e3822b59 Fix for #12945: ProgressBar.setMax() will always redraw.
Fix for issue #12945: Changing the maximum of a progress bar does
not cause it to be redrawn, even though a new maximum changes the
position of the current progress in relation to its maximum. With this fix,
setMax() will always cause refreshProgress() to be called if the maximum is
different than it was before.

Change-Id: I971ec3302953bcadc0aac3dd8241481bab2b5a91
2011-02-17 20:56:29 -08:00
Gilles Debunne
ad8484b379 Cursor does not jump back to its previous position when IME is showed up.
Bug 3441308

This behavior may be restored for phones if appropriate.

Change-Id: Ibc2de587d64d372521da2d54f239cab56f04b407
2011-02-17 17:37:51 -08:00
Gilles Debunne
46b7d441c6 Composing span is removed when insertion point is moved
Bug 3457633

Change-Id: I8896823b7e700dd52acec180c2a1d8e2f6ac5ae1
2011-02-17 16:03:12 -08:00
Adam Powell
b7c1b20c8a Fix bug 3465210 - Anchored popups don't appear above anchor when there
isn't enough room.

Oops. Fix a regression introduced by recent changes.

Change-Id: I413998dc2413763f2ea3f31a7ca68f098be19b36
2011-02-17 12:09:38 -08:00
Adam Cohen
4f67440752 Merge "StackView rendering fix for non-hardware accelerated apps and hardware layers" 2011-02-16 17:12:25 -08:00
Adam Powell
348e69cfab Fix bug 3413800 - Revise AutoCompleteTextView dropdown behavior
Be more conservative with when we let an AutoCompleteTextView's
dropdown box of completion suggestions cover the IME.

Disable the expand-when-touched behavior of the dropdown list when
more than 3 items can be seen at a time without it.

Don't let a ListPopupWindow that is expanding in response to touch
scroll the anchor view within its parent and slide the dropdown out
from under the user's finger.

Change-Id: I009accfd4e841c9a5e1072735d8a0b067a0bc06a
2011-02-16 16:55:45 -08:00
Adam Cohen
1ff65d105a StackView rendering fix for non-hardware accelerated apps and hardware layers
Change-Id: I34a0362cd37c6b95a0b3196302b6510b0f7ad34e
2011-02-16 14:04:09 -08:00
Scott Main
55cdc0c904 am 0ab1b326: am 13033ea5: docs: fix misc broken links
* commit '0ab1b326c72afb2bd7798462fcdd8e5d3b440fd2':
  docs: fix misc broken links
2011-02-15 20:15:00 -08:00
Scott Main
13033ea527 docs: fix misc broken links
Change-Id: Id7d0ee36398aca452ceb2c3d15982397f58a06c6
2011-02-15 16:00:37 -08:00
Adam Powell
99c4032fb3 Merge "Fix bug 3362273 - Make overscroll glow appear within padding region" 2011-02-15 15:07:55 -08:00
Adam Powell
7d86378b0c Fix bug 3362273 - Make overscroll glow appear within padding region
Change-Id: I3c6513ada6bdd192c83f3ff59a2c85717156de22
2011-02-15 15:05:03 -08:00
Amith Yamasani
5101e1ed51 Merge "Don't change keyboard state in setIconifiedByDefault." 2011-02-15 13:06:20 -08:00
Amith Yamasani
1b64c3b5fe Don't change keyboard state in setIconifiedByDefault.
Bug: 3225887
Bug: 3453253 (possibly)

Since some apps call setIconifiedByDefault(false) at the initialization step,
it isn't a good idea to open/close the keyboard during this call. Apps
can call setIconified(false) instead to invoke the keyboard.

Change-Id: I9d5d08b74055a3e99053d647df0cd4c7953bae80
2011-02-15 12:02:45 -08:00
Adam Powell
5fd8dd01a7 Merge "Fix some bugs with MenuPopupHelper and ListPopupWindow" 2011-02-15 11:16:01 -08:00
Gilles Debunne
05cc6dbf70 Merge "Text insertion cursor is now defined by a Drawable." 2011-02-15 10:41:30 -08:00
Adam Powell
ca51e8788a Fix some bugs with MenuPopupHelper and ListPopupWindow
Clean up handling of a few conditions in MenuPopupHelper that the
monkeys manage to trigger around the use of ViewTreeObserver. (bug
3443819, bug 3312949)

Fix a bug where a stale handler message could cause a ListPopupWindow
to reopen itself after being dismissed. (bug 3453607)

Change-Id: I488014767ccee785500862a2572beb35901d173b
2011-02-14 19:54:29 -08:00
Gilles Debunne
f75c97e023 Text insertion cursor is now defined by a Drawable.
Bug 3261766

If defined, the drawable is used instead of directly drawing a 1 pixel
line. This makes the cursor more fancy and more visible.

The drawable is currently clipped by the TextView's limits, which is
currently visible on the left when the cursor is at the first position.
To solve this issue properly, we would need to propagate a do-not-clip
up in the hierarchy.

Change-Id: I99f6001048eed14104994acf6bab942dda8eb38e
2011-02-14 18:29:39 -08:00
Romain Guy
cfe8903441 Merge "Gracefully handle drawing caches allocation failure. Bug #3431451" 2011-02-14 16:34:15 -08:00
Romain Guy
0211a0a10d Gracefully handle drawing caches allocation failure.
Bug #3431451

This bug was causing ListView to not render properly when showing an item
larger than the maximum drawing cache size. ListView relies on the drawing
cache to correctly mask all the background pixels. However, if the cache
is not properly created, the background will show through even though
ListView.isOpaque() == true. This change detects this case and falls
back to the default non opaque behavior.

Change-Id: I30a45e7a03fb7ebb2b12f0e85c075c2901954c44
2011-02-14 16:34:59 -08:00
Adam Cohen
0b96a57c85 Making AdapaterViewAnimator setDisplayedChild remotable
Change-Id: Idee91f457e1d4316feb077aaa949baa54eca6ab1
2011-02-14 11:37:26 -08:00
Adam Cohen
f3032e9d9d Merge "Fixing a bug in RemoteViewsAdapter where cached items weren't being marked as requested" 2011-02-11 18:25:43 -08:00
Adam Cohen
aeb66ca473 Fixing a bug in RemoteViewsAdapter where cached items weren't being marked as requested
Change-Id: I1275cbbcd949d27c1c7444a9fb7a684ae7d7eb25
2011-02-11 13:33:41 -08:00
Chih-Chung Chang
d4c5b7651f Merge "Fix a bug that the condition for play/pause was reversed." 2011-02-10 19:23:52 -08:00
Adam Powell
96bad13901 Merge "Fix bug 3440372 - Spinner measurement issues with new rules" 2011-02-10 12:07:38 -08:00
Adam Powell
b70c727b2e Fix bug 3440372 - Spinner measurement issues with new rules
Change-Id: I3633239dc42277eb6447cf7f0907f35f4b45e873
2011-02-10 12:04:59 -08:00
Chih-Chung Chang
d7db70123f Fix a bug that the condition for play/pause was reversed.
Change-Id: I462ca5b910de98a875d7f54b4a937176f88474d0
2011-02-10 18:17:38 +08:00
Gilles Debunne
711734a2f8 AutoComplete list does not hide the IME when it re-appears.
Bug 3415891

With the current behavior, as soon as the list is expanded by
'long' pressing on or scrolling its content, it will always further appear
in its long state, thus hiding the IME.

This fix changes this behavior so that the default state is always
compact, not hiding the IME, and an explicit expansion
is always required.

Also fixes a bug in ListPopupWindow that prevented the timer that
expands the list from being started.

Change-Id: I896e92d54961769c10b276c36f6510e91ff096a2
2011-02-09 16:56:13 -08:00
Gilles Debunne
a4a5758b5f The tab key completes text in AutoCompleteTextView.
Bug 3330651.

The first item in the list is not selected by default. From discussions
in other related bugs, there does not seem to be an agreement on this.

Supporting the actual token separator has also been punted. This would
require a new method in the Tokenizer, which could be ill-defined for
exotic tokenizer, plus typing a comma (for instance) to achieve a
completion is not a common pattern.

Change-Id: I30baf62077c412256175f871d21f4841e104f212
2011-02-09 16:54:18 -08:00
Gilles Debunne
8e28ab22de am 2050de5b: Text selection is broken.
* commit '2050de5b9a5c097e30545ab822211d49031bd9dc':
  Text selection is broken.
2011-02-09 16:49:42 -08:00