Commit Graph

2027 Commits

Author SHA1 Message Date
Adam Powell
62e2bdecc2 Fix bug 5165223 Fix Holo Spinner item/dropdown alignment.
Fix bug 5117565 Spinner popup extends out of screen bounds.

Change-Id: I7fef7bbe98aa26611c498d1fe875e84db57dcda0
2011-08-15 16:54:40 -07:00
Adam Powell
e21f89c802 Merge "Fix bug 5159596 - Slider grabs touch point when trying to scroll a list" 2011-08-15 10:29:10 -07:00
Gilles Debunne
186c1683ce Merge "Text suggestions are enabled for a subset of input types" 2011-08-15 10:07:59 -07:00
Adam Powell
1029866a12 Fix bug 5159596 - Slider grabs touch point when trying to scroll a list
SeekBar widgets were not good citizens when placed in scrolling containers.
Detect when a SeekBar being touched is in a scrolling container and fall
back to a touch slop-based method for beginning a drag. Taps along the
seek bar itself will still change the value on touch up, even if the touch
slop never initiated a proper drag.

Factor out the code used to determine scrolling container status in View
into something that can be reused elsewhere in the framework; leave it
@hidden for now.

Change-Id: I59a21e8ab2c3b0092fafedbcd6ae1ee15f45971c
2011-08-14 18:29:23 -07:00
Gilles Debunne
248b112dda Text suggestions are enabled for a subset of input types
Change-Id: I0e521eec2784af99ff741a1132a3bc3f7b7aa071
2011-08-12 13:57:45 -07:00
Gilles Debunne
1329192fc3 Merge "Bug 5150869: Text selection enabled in browser." 2011-08-12 11:36:50 -07:00
Gilles Debunne
2237829e77 Bug 5150869: Text selection enabled in browser.
After text selection is started, rebuildWebTextView is called, which
calls setHorizontallyScrolling with false (multi-line). This was already
its value, but since there was no test for a value change, the layout was
nulled and this stops the selection mode.

Change-Id: I99aadbf45fca4fbdbe8ab7266fe9a7ff839e2792
2011-08-12 10:43:51 -07:00
Dianne Hackborn
8a5c6617d5 Merge "Fix issue #5016544: IME keyboard hides folder rename text field." 2011-08-11 11:38:32 -07:00
Gilles Debunne
072b50c667 SuggestionEnabled flag enforced in ActionPopup
Also removed the Nothing to paste string (and its references)

Change-Id: Iaed952075e9e72dcb962ca52341615bc57cb4047
2011-08-10 14:13:17 -07:00
Daniel Sandler
ffad0cf83d Merge "Fix obviously broken DateTimeView.onAttachedToWindow()." 2011-08-09 19:35:57 -07:00
Adam Powell
74df8e3492 Merge "Flingable switches" 2011-08-09 16:38:21 -07:00
Adam Powell
01d11edc1e Flingable switches
Change-Id: I640656358cf28569242d900d41493a69845f7305
2011-08-09 16:32:12 -07:00
Amith Yamasani
5607a38271 Added methods to change text entry mode in SearchView.
Bug: 5143618

Handle imeOptions and inputType attributes in SearchableInfo.
Methods to directly modify those attributes on SearchView.

Change-Id: I340617767f930ecb1b1ad5ab2696bc613982a20b
2011-08-09 15:16:08 -07:00
Dianne Hackborn
70a3f677bf Fix issue #5016544: IME keyboard hides folder rename text field.
Tweak some issues in TextView with the focus rect used to determing
where the scroll position needs to be.  The ultimate problem was that
in various situations it would use the right-most selection position
cursor as the scroll location and when it adds 1 to make this a valid
rect we end up with a rectangle that is outside of the view.

Change-Id: Ia200c58e4e014d2a0a1be4761f9a1e5eb702a8e5
2011-08-09 11:11:25 -07:00
Gilles Debunne
1f6ac8b1e0 Merge "Handles' position are updated in case of external change." 2011-08-09 10:22:15 -07:00
Gilles Debunne
b932146135 Merge "The PASTE action is always displayed, even when starting a selection" 2011-08-09 10:22:02 -07:00
Daniel Sandler
8d3c234407 Fix obviously broken DateTimeView.onAttachedToWindow().
Change-Id: I6b9e948d26b4c22b4520ca48b71c1f7e45ca7899
2011-08-09 13:10:20 -04:00
Adam Powell
50d3c667eb Merge "Fix bug 5135608 - Let AbsListView take focus while detached" 2011-08-09 00:03:16 -07:00
Adam Powell
b3750133db Fix bug 5135608 - Let AbsListView take focus while detached
While it is valid to request focus while detached from a window,
AbsListView did not handle it gracefully if it had an adapter whose
data changed while the view was detached, since DataSetObservers are
unregistered during this time. Assume that the data could have changed
if we gain focus while detached.

Change-Id: Id135693ffcc48ff5a9d530d335ab449180624c43
2011-08-08 23:50:25 -07:00
Daniel Lehmann
f6d3079f98 Merge "Don't perform query if QuickContactBadge has been initialized via assignContactUri" 2011-08-08 13:06:01 -07:00
Adam Powell
3a02ff1300 Merge "Fix bug 5112702 - switches should have "ON" on the right" 2011-08-08 09:53:36 -07:00
Daniel Lehmann
e13e55b9bb Don't perform query if QuickContactBadge has been initialized via
assignContactUri

Also changes:
 - Remove handling of mMode, as QuickContact now ignores this anyway
 - Don't draw the overlay-triangle if no action can be performed

Bug:5132023
Change-Id: I8d6f8df9caf140fdade8683bd7b22d53c28994f4
2011-08-07 19:51:28 -07:00
Adam Powell
ec1d60369f Fix bug 5112702 - switches should have "ON" on the right
Make Switches obey the Grand Unified Theory of Button Ordering.
This also matches their behavior with volume/brightness sliders.

Change-Id: I4e72801e81b10002542a05f61c99a57991f130ff
2011-08-07 18:03:39 -07:00
Adam Powell
a7845ed44a Fix bug 5124712 - allow partial items when measuring height of list popups
Change-Id: I59c9fc6d5dcd21679ba67d7c233ecd9d7e19d21c
2011-08-07 15:48:25 -07:00
Gilles Debunne
cb2516bb66 The PASTE action is always displayed, even when starting a selection
Change-Id: I5269490f411de2bf6195956aead240a3908026e7
2011-08-05 17:02:54 -07:00
Gilles Debunne
232cbab493 Handles' position are updated in case of external change.
A 'Select All' for instance will alter the selection and the handles
have to updated accordingly.

Change-Id: I8ac91c858e7944a7b4ce1b37a3d90609a3003d22
2011-08-05 16:54:45 -07:00
Philip Milne
c218cacee0 Merge "Remove call to setPadding() in setUseDefaultMargins()." 2011-08-05 11:32:20 -07:00
Philip Milne
b559976a50 Remove call to setPadding() in setUseDefaultMargins().
It is not possible for teh user to override the assigned padding values
because the XML attributes are processed in the opposite order.

Also, make the XML and Java examples grid3.xml and Activity2.java
consistent in preparation for a move to API demos.

Change-Id: I47334f9f5a46a8a528067d88350dd70eaa38ff33
2011-08-05 11:24:55 -07:00
Adam Powell
f14f8ddd95 Merge "Fix bug 5118908 - ImageView.setImageDrawable always requests layout" 2011-08-04 18:32:18 -07:00
Adam Powell
2a0e99da03 Fix bug 5118908 - ImageView.setImageDrawable always requests layout
Make ImageView a bit more conservative about when it requests a
layout. This improves performance for ListViews where apps
asynchronously load images and replace placeholders outside of the
optimized getView path.

Change-Id: I564a4a343ab9c8c2d5baf907b5f573b5ee02c87a
2011-08-04 18:30:46 -07:00
Amith Yamasani
f88f8c92df Merge "Don't call onQueryTextChanged more often than necessary." 2011-08-04 18:25:32 -07:00
Amith Yamasani
b47c4fd206 Don't call onQueryTextChanged more often than necessary.
Also update the hint text if iconifiedByDefault changes.

Bug: 5097238
Change-Id: I876b3f3e74c30230f68d6bc88a95e182e4cc652b
2011-08-04 14:30:07 -07:00
Adam Powell
0a2a287987 Merge "Fix bug 5073637 - Market apps crashing FastScroller" 2011-08-04 10:51:57 -07:00
Adam Powell
568ccd88d7 Fix bug 5073637 - Market apps crashing FastScroller
It seems that some popular Market apps do not properly implement
SectionIndexer#getSectionForPosition and the framework did not
previously call it. Revert to more simplistic scrollbar behavior for
apps targeting sdk < Honeycomb.

Change-Id: If0b1f2b4db540de4bb8ba45798e498c09cddb42f
2011-08-04 10:36:37 -07:00
Svetoslav Ganov
7abaecc3db Merge "Removing firing of spurious scroll accesibility events." 2011-08-04 05:55:46 -07:00
Svetoslav Ganov
2c44b9221b Merge "No selection or click accessibility events are fired when a list item is tapped." 2011-08-04 05:55:26 -07:00
Philip Milne
271865565a Merge "Tidy." 2011-08-03 16:01:59 -07:00
Philip Milne
4c8cf4c933 Tidy.
Simplify logic for alignment modes.
Simplify drawing of rectangles.
Remove redundant code that was generating warnings in IDEA.
Remove the flexibility variable from Spec as it always has the value UNDEFINED.
Supress remaining inspection warning for clean (green) inspection status.

Change-Id: I2ddd80c68e7a6db0877648c2fdecefe9dbe7d32f
2011-08-03 15:37:05 -07:00
Gilles Debunne
eba69ac070 Merge "A tap on the insertion handle is only handled if it has not been moved" 2011-08-03 15:01:50 -07:00
Gilles Debunne
c0e74ca822 Merge "Bug 5050963: Suggestion popup moves with its associated TextView" 2011-08-03 13:58:49 -07:00
Gilles Debunne
040023a481 A tap on the insertion handle is only handled if it has not been moved
Without this test, an arbitrary drag of the handle that happens to end next to
where it started triggers the replace/paste action popup window, which is very
confusing.

Change-Id: Ib1f848147a1c12c231a28f2e730eccaf5321f85c
2011-08-02 20:16:32 -07:00
Gilles Debunne
21078e4349 Bug 5050963: Suggestion popup moves with its associated TextView
Generalisation of the onPreDraw listener pattern for all popup windows
(SuggestionsPopupWindow, ActionPopupWindow and HandleView).

Added a shared PositionListener class that tracks movements of the
parent's TextView and limit calls to hierarchy to get this position from
different places.

See also bug 5106062.

Change-Id: Ia2fe9509fa7df683acc859f9871bf4630c2da4dc
2011-08-02 18:00:48 -07:00
Romain Guy
04ee7956ea Merge "Add the ability to enable/disable marquee fading per device" 2011-08-02 17:03:22 -07:00
Dianne Hackborn
5857bceaea Merge "Clear the bitmap from the canvas in a lot of places." 2011-08-02 16:57:50 -07:00
Dianne Hackborn
6311d0a079 Clear the bitmap from the canvas in a lot of places.
Change-Id: I6b2071ac7b348c473b9bdd1b972d095aebbb4fb3
2011-08-02 16:37:58 -07:00
Romain Guy
6805545649 Add the ability to enable/disable marquee fading per device
Change-Id: I4211553455e87f0af598a2fac1d4f65f15c294fc
2011-08-02 16:33:02 -07:00
Philip Milne
e10bcdb37c Merge "Fix for http://b/issue?id=5081478" 2011-08-02 16:22:26 -07:00
Philip Milne
899d592287 Fix for http://b/issue?id=5081478
GridLayout needs to call measure on children after it knows how large children should be

Also:

. Remove deprecated methods and XML attributes.
. Stop Spaces having margins by default.
. Remove getSpacers() and findUsed()
. Change default for row/columnOrderPreserved() from false to true.
. Improve automatic index allocation mechanism to use individual maxima.

Change-Id: Id79fbb2e70a0bf2002191ec2a9746547d896de72
2011-08-02 16:01:28 -07:00
Bjorn Bringert
dbe55b722c Merge "Fix exception when a focused item is detached." 2011-08-01 13:39:30 -07:00
Mark Brophy
1ea6889136 Fix exception when a focused item is detached.
When a ListView has itemsCanFocus set, and scrolling moves the currently
focused item off the display, its focus is cleared. This is checked by
calling getDistanceToView().

However, it's possible that the view will have been recycled.  If so, it
will have been detached from the parent by calling
ViewGroup.detachViewFromParent.  Since this doesn't clear the view's
focus, we'll still try to call getDistanceFromView(), causing an
IllegalArgumentException since the view is not a descendant of the
ListView anymore.

Check whether the view is still a descendant before calling
getDistanceToView(). If it's not, we also need to clear the focus.

Bug: 4556022
Change-Id: Iebee56032223b70d714e2ec3bb7a19093ab5f81c
2011-08-01 16:32:03 +01:00