* changes:
FalsingManager Quick settings fix
Fixed a bug where the panel could be too small in certain cases
Fixed a bug where the margins where not updated correctly
Fixed the handling of the expand on the lockscreen
Remove code duplication in SelectionStartHandleView and
SelectionEndHandleView by introducing SelectionHandleView.
Change-Id: I4486019714b13d184a72cf7ee60c346c4d8b5f5a
When updating a notification, the end margin was not
correctly updating, leading to overlapping text with
the image.
Change-Id: Ica3d21ff0268105d0a8a73527b8dad0225e12d5a
If there is an image instead of applying the same
margin everywhere, the text now floats around the
image.
Change-Id: I87f9ca9f51fb270b0732a99374544381bd1fc4e0
Most of the notification templates have been updated.
Some cases like media notifications don't yet work well
but will be fixed in a later CL.
Bug: 25376106
Change-Id: I26c366e58ebba3852cea20de6fca311bd302bb24
Previously we would check whether relayout was required and optionally
invalidate; however, with partial layout we leave this work for the
makeNewLayout() method. We still need to manually invalidate, though,
since makeNewLayout() does not handle invalidation.
Bug: 25857300
Change-Id: I81ef9062c9fb4964d5e42a3562e6c782492ad65f
This is a mechanical replacement of Context.getSystemService(String)
with Context.getSystemService(Class<T>) when retrieving
InputMethodManager. Note those are bundled code. Hence we don't need
to make sure Build.VERSION.SDK_INT >= 23.
Change-Id: Icc64942ad8f11e44bf84f8d4fe476b2fdd1257f3
- Set an id for each HandleView to access the hanlde.
- Rename DragOnTextViewActions to DragAction to use it for
dragging handles.
- Introduce HandleCoordinates to provide proper coordinates
for handles.
More tests will be added in following CLs.
Bug: 25730231
Change-Id: I9276bf2f983983ec9aae0ddcf674d3dcee566892
To make suggestion window style Material, this CL does following things:
1. Introduce LinearLayout to be able to split suggestion item and menu.
Currently suggestion menus, "Add to Dictionary" and "Delete" buttons
are children of ListView. It is necessary to introduce LinearLayout
and move these two menus from ListView to this LinearLayout to have a
divider between suggestion items and menus.
2. Extract suggestion window layout definition from Java.
Currently almost all layout of suggestion popup window is done by
Editor.java. By extracting this logic from Java and move it to XML
files, it becomes easy to support both Holo and Material theme.
3. Introduce Material Design.
Suggestion window should respect the running application's theme since
suggestion window is shown as the part of the application.
This patch introduces Material themed suggestion window, and at the
same time, the old window is also kept as the Holo themed suggestion
window.
Bug: 15347319
Change-Id: Ieccea12db95c0a040b38680ae794b1cf6971736f
Previously the dismiss callback was called immediately after the menu
received a close request; however, the dismiss callback implies that
the menu's window has finished animating and been removed from the
window manager.
Also cleans up handling of mPopup in MenuPopupHelper to prevent
unnecessary MenuPopup allocations and convert unnecessary fields into
method arguments.
Bug: 25323707
Change-Id: I8e3877ae6c40b4d0f1df23a4ff4fa48a7df34e0d
NearestTouchDelegate may still be assigned to non-ViewGroup views, but
we won't attempt to find a target child View until the touch moves into
a ViewGroup.
Bug: 25813455
Change-Id: I570f88fee63623110e3463e8d4579cca8113fd5e
A previous CL removed setLocale(), which had been initializing the temp
calendar. This CL also makes the calendar final, since the locale is only
set once during construction.
Bug: 25776094
Change-Id: If0af34df3120a7c4b1667129a553b9f8b7ec1999
Traditionally, when a view called requestLayout it would force
recursive requestLayout calls for all parent views up the
hierarchy. This meant that there was no way to determine at traversal
time whether a parent view itself needed layout, or if just one of its
descendants did.
Add a ViewParent method requestPartialLayoutForChild(View). This lets
a caller state that a particular child of a given parent needs a
remeasure and relayout at its current measured size and position
within that parent. This can help prevent the full-tree relayout often
caused by otherwise trivial changes. Partial layouts are processed
after any pending "full" relayout during ViewRoot traversals, but
before drawing.
Add a ViewGroup method requestLayoutForChild(View). This lets a
ViewGroup decide whether it is more appropriate to request a
traditional relayout or a partial layout for itself or just the child
that changed.
Add a ViewParent method findDependentLayoutAxes. This allows a caller
to check if the ViewParent's layout is dependent on a specific direct
child view along one or both axes. Called recursively, this can be
used to determine if a change in a child view can be isolated to a
partial layout, even if its direct parent's own layout is tied to its
other ancestors. (e.g. MATCH_PARENT, LinearLayout weights)
Implement ViewGroup#requestPartialLayoutForChild to call new
ViewParent method findDependentLayoutAxes and based on the result,
either request a full layout for itself or a partial layout for the
child in question.
Implement findDependentLayoutAxes for common framework ViewGroups. A
private implementation in ViewGroup is available for use by framework
classes that will deal with basic LayoutParams. These implementations
specifically check for derived LayoutParams classes and abort the
optimization if they find something beyond their expected parameter
types.
Change-Id: I0a1a9b79293d17d4fae8d9892b96d3586f9401ae
Previously, TextView setText and append methods set the movement
method to LinkMovementMethod only when autoLink was enabled and
Linkify was able to find links in the input text. This CL adds the
case where autoLink is false, linksClickable is true, and the input
text contains ClickableSpans.
Fixes https://code.google.com/p/android/issues/detail?id=2219
Bug: 1712837
Change-Id: Ife4e35bac7f6cb48ad0dac6ecb4b90aec126fc73
We want to limit the number of size thresholds that an application will
report. Instead of using a dimen resource that will increase the number
of thresholds, we calculate the max number of action buttons dynamically
in code.
Bug: 25394588
Change-Id: I8ece331cd02fb116b49734003cec112708d27f85
No functional changes, only refactoring:
- remove unused mShowCascadingMenus member variable
- move private interface implementations to anonymous inner classes
- move interfaces to end of class
- clean up docs formatting
Change-Id: Ib82ca0d3a3ff49207959a17b77c4ff4f11a1afc2
No functional changes, only refactoring:
- shorten method and variable names
- remove unused validation callback
- avoid using return in setters
Change-Id: Ie7c19cfe3c5cb515695f943c534899d37ad032bb
Bug 24873983
Focus moves properly within the SimpleMonthView and between
components of the DatePicker.
Change-Id: I61778f9b4f19536ff6c7a512f9b4faf7bf4447a7
Bundles cascading menu information and stores it in a stack representing
the hierarchy of added menus.
Bug: 23970448
Change-Id: I1621d9eb30ff173767b6ebad2a1977127c42d0ad
-1, 0, 1, and 2 were directly used for the return value of
TextView@doKeyDown. It's very hard to understand what each
value means.
Change-Id: I88dad15e2b68f652c8479a01f9f241c6638b5284
Also enlarges the touch targets for the AM/PM buttons by redirecting
unhandled touches within the containing view group.
Bug: 20257430
Change-Id: I28e8d8894a4702116bb68cc6a6d4115e5aa87a69
A crash occured on updating after calling removeSelection with showing
selection handlers. This was because some selection-handler code didn't
consider the case the selection index was -1 (-1 means there is no selection).
This patch fixes this crash.
Bug: 23299977
Change-Id: I736d315e073f773aec597522203015205a8da42b
onPreDraw starts an action mode in extract mode only which
does not consider the type of motion event and since extracted
mode never gets the focus event it never hides so it does not
need to show again.
Stop starting an action mode onPreDraw in extracted mode and
let the onTouchEvent handle starting the mode.
Also re-enabled dragging and dropping for ExtractedMode (most
of the issues were caused by starting the action mode
onPreDraw).
Bug: 25102276
Change-Id: I90d8e9f42f395b6b529e4d023ba6939e0dfb147f