Commit Graph

4418 Commits

Author SHA1 Message Date
Cyril Mottier
d40acfb89e Return the actual interpolator of the ViewPropertyAnimator
The implementation of getInterpolator() was always returning null
(probably a quick copy-paste from the default Animator implementation).
This patch fixes the problem by returning the interpolator set by
setInterpolator(TimeInterpolator) or the default one if none has been
set yet.

This patch also avoid creating multiple instances of ValueAnimator in 
order to retrieve some default values.

Change-Id: I8880f419f021a8b980fb32bebe927915fde19bf7
2013-07-25 10:08:29 +02:00
Romain Guy
dbfb2ab4a7 am 93d46952: am 67603c6e: Recreate TextureView\'s display list on attach Bug #9425270
* commit '93d46952db60090ae22bc8197659a06ae23cb58b':
  Recreate TextureView's display list on attach Bug #9425270
2013-06-27 14:52:33 -07:00
Romain Guy
67603c6e1b Recreate TextureView's display list on attach
Bug #9425270

When a TextureView is detached from its window and immediately
re-attached, the display list is not destroyed but reused as is.
TextureView will however destroy the layer and surface texture
reference by the display list.

The solution is to force TextureView to invalidate its display
list on re-attach if it previously had a surface/layer pair.

Change-Id: I475096ffa7e5709155c4c943bf1bfaaaedbd4a1d
2013-06-27 10:58:10 -07:00
Scott Main
ea8935362d am c4473d10: am 27a8508e: add attributes reference for splimotionevents and layoutmode
* commit 'c4473d10ed747fb1e84efff7183023e0ecc1a493':
  add attributes reference for splimotionevents and layoutmode
2013-06-17 18:39:18 -07:00
Scott Main
27a8508ee1 add attributes reference for splimotionevents and layoutmode
Change-Id: Id78f2957c994fc30a0837084f22766c8cfa70fe8
2013-06-18 01:33:33 +00:00
Romain Guy
7a6e129759 am 8d8fc469: Merge "Don\'t orphan footers with transient state Bug #8725945" into jb-mr2-dev
* commit '8d8fc469952ffe3feb45e52388f2129f8dd5e40c':
  Don't orphan footers with transient state Bug #8725945
2013-06-10 10:26:57 -07:00
Romain Guy
b7e0f7942b Don't orphan footers with transient state
Bug #8725945

Selecting text in an EditText causes the View to have transient
state. This would in turn cause the View to be removed from its
ListView parent. When removed, the EditText would lose its
AttachInfo, causing all sorts of problems. Headers and footers
must not be removed, only detached. This is the part of the fix
in AbsListView.

Fixing AbsListView triggered a second bug: when a View is removed
from the Window manager, it would keep its parent assigned, thus
making it impossible to add it again to the window manager. When
a ViewRootImpl goes through doDie(), it must set its content view's
parent to null to properly cleanup.

Change-Id: I0489daa74f8f7fcf85526f0928f8925ec30d4f42
2013-06-07 15:36:49 -07:00
Jean Chalard
44baed2dc3 am af9e5e5f: Merge "Improve the documentation for InputConnection." into jb-mr2-dev
* commit 'af9e5e5f618448f77f74bb36e0adbe88cb2ae156':
  Improve the documentation for InputConnection.
2013-05-30 19:47:41 -07:00
Jean Chalard
e811de2d6c Improve the documentation for InputConnection.
- Add many details to most methods.
- Add comments specific to IME authors and to editor authors.
- Add missing return value docs.
- Straighten out single-spacing vs double spacing.

Bug: 8843866
Change-Id: If1f6dcf0457d5332a7ebb1ebfb1967c6ff0df722
2013-05-30 18:03:39 +09:00
John Spurlock
c00930f4fe am 50ef7ab7: Docfix: remove confusing "disabled" link label.
* commit '50ef7ab70ad02deb9ad3694fb894741d6007564a':
  Docfix: remove confusing "disabled" link label.
2013-05-29 15:18:51 -07:00
John Spurlock
50ef7ab70a Docfix: remove confusing "disabled" link label.
Change-Id: I1acb9c8c20b6cda0e6cfb2fc1e450f37e7cd4eeb
2013-05-29 17:43:16 -04:00
Jeff Brown
c8a7773562 am dea6e86d: am 3422ceb6: Merge "Bug fix for building the hover target list"
* commit 'dea6e86dce716b67fe92c9b281fe9e79256f3b78':
  Bug fix for building the hover target list
2013-05-28 15:49:13 -07:00
Jeff Brown
dea6e86dce am 3422ceb6: Merge "Bug fix for building the hover target list"
* commit '3422ceb6ba453c28ac39dfce34534e0346394a3a':
  Bug fix for building the hover target list
2013-05-28 15:46:00 -07:00
Jeff Brown
3422ceb6ba Merge "Bug fix for building the hover target list" 2013-05-28 20:04:23 +00:00
John Spurlock
be7a7e546f am ee352cca: Merge "Fix typo in View.java javadocs" into jb-mr2-dev
* commit 'ee352cca1f3beb577dfdf1c18a08242e4f94d01b':
  Fix typo in View.java javadocs
2013-05-28 09:36:19 -07:00
John Spurlock
44b1edd948 Fix typo in View.java javadocs
Change-Id: I85b9b2bd30d1f9d38954c31f24a352930a230ced
2013-05-28 11:40:58 -04:00
Romain Guy
469cc57ca7 am 2f35d244: Merge "Avoid extraneous EGL surface allocations Bug #8667873" into jb-mr2-dev
* commit '2f35d2441e59b996a56653881fdc2f52d4eeb644':
  Avoid extraneous EGL surface allocations Bug #8667873
2013-05-21 19:11:16 -07:00
Romain Guy
2f35d2441e Merge "Avoid extraneous EGL surface allocations Bug #8667873" into jb-mr2-dev 2013-05-22 02:08:24 +00:00
Romain Guy
370ab062a0 Avoid extraneous EGL surface allocations
Bug #8667873

windowShouldResize means we need to layout the window, it doesn't mean
the dimensions of the surface have changed. We should only check the
width and the height. With this fix we can avoid a surface allocation
every time the window shade is opened or closed.

Change-Id: I8afe97b820a865723f2aab7a5aa4ddc8eaaec6e1
2013-05-21 12:15:07 -07:00
Svetoslav Ganov
5315953b86 am 78a4630e: Merge "Taking into account data change for AbsListView when prefetching node infos." into jb-mr2-dev
* commit '78a4630edaa11846b09bdad84bac18a0441c500a':
  Taking into account data change for AbsListView when prefetching node infos.
2013-05-20 15:43:36 -07:00
Svetoslav Ganov
78a4630eda Merge "Taking into account data change for AbsListView when prefetching node infos." into jb-mr2-dev 2013-05-20 22:41:28 +00:00
Chet Haase
e8d6dc4cad am 865cffc7: Merge "Add null check in ViewOverlay" into jb-mr2-dev
* commit '865cffc7cece8f10a9e6aab1e89a92c8794cb279':
  Add null check in ViewOverlay
2013-05-20 13:43:36 -07:00
Chet Haase
d8b0b23324 Add null check in ViewOverlay
View.getOverlay().clear() can failed with an NPE if there are
no drawables in the overlay. Fix: add a null check before dereferencing
the mDrawables field.

Issue #8895794 getOverlay.clear() crashes if drawables were not added previously

Change-Id: I9b2a63036450915681ba3a89a0911e2490063702
2013-05-20 07:57:02 -07:00
Svetoslav Ganov
50776863a2 Taking into account data change for AbsListView when prefetching node infos.
We are prefetching accessibility node infos to minimize the number of IPC
calls when an accessibility service introspects the screen. It is however,
possible that the view we are prefetching is a child of an AbsListView whose
adapter changed its data but the AbsListView still did not perform a layout
pass to sync its children with the new adapter state. This may lead to an
exeption when trying to query for the state of a child's position. If the
data of the adapter is changed and the layout pass still not performed,
we return null for the AbsLIstView's children. When the layout pass
completes we already notify the accessibliity layer so it will be able to
refetch the children of the AbsListView.

bug:8433433

Change-Id: I56313c721aef3848b15fad50027d068ba1d291f7
2013-05-17 18:36:57 -07:00
Chet Haase
944a8725e6 am bee0495f: Merge "Dirty rect must expand, not contract." into jb-mr2-dev
* commit 'bee0495fa17b7e385d880f18e510e295c000cfa9':
  Dirty rect must expand, not contract.
2013-05-15 13:35:09 -07:00
Chet Haase
5495c72612 Dirty rect must expand, not contract.
Different devices have different precision, leading to different pixels
being touched during rendering operations. We need to ensure that the
dirty rect we draw with (and which gets erased on the following frame)
encompasses all possible pixels instead of some ideal rounded rectangle.

The bug from this code led to dropped-pixels artifacts on some devices,
where we'd scale a view, drawing it into some pixels, then invalidate
that same area on the next frame, but the invalidation rectangle didn't
cover the same pixels as the device drew into.

The fix is to floor() the left/top pixels and ceil() the right/bottom
pixels of the transformed invalidation rectangle.

Issue #8971348 dropped pixel artifacts during some scaling operations

Change-Id: Iedb1afd5621dff43bf7a3919bdbd8d2251647fd2
2013-05-14 21:19:48 -07:00
Svetoslav
80127981f8 am c0a979ce: Merge "Fixing the accessibility text traversal in extend mode." into jb-mr2-dev
* commit 'c0a979ce30cf9b96c0a84d0679aeeef7153a22fa':
  Fixing the accessibility text traversal in extend mode.
2013-05-14 11:07:08 -07:00
Svetoslav
c0a979ce30 Merge "Fixing the accessibility text traversal in extend mode." into jb-mr2-dev 2013-05-14 17:39:36 +00:00
Kristian Monsen
3d1edc033f am 6e7ed13b: Merge "Fix for bug 8623163: Call view methods on the UI thread" into jb-mr2-dev
* commit '6e7ed13b12edc9e02580a273c3aa546e62231b5a':
  Fix for bug 8623163: Call view methods on the UI thread
2013-05-13 02:33:01 -07:00
Kristian Monsen
6e7ed13b12 Merge "Fix for bug 8623163: Call view methods on the UI thread" into jb-mr2-dev 2013-05-13 09:30:07 +00:00
Svetoslav
abad55d860 Fixing the accessibility text traversal in extend mode.
We added APIs to allow an accessibility service to extend the
selection while moving the cursor at a given granularity such
as word, character, etc. The problem is that the traversal was
extending only the end of the selection while moving forward
and the start of the selection while moving backward. This leads
to a case in which the user cannot shrink/extend the selection
because for example instead of shrinking the end of the selection
the implementation was extending the start.

Now extending the selection moves only the selection end. This is
the same behavior as text view using a keyboard.

Tests: https://googleplex-android-review.googlesource.com/#/c/307062

bug:8839844

Change-Id: Id6965b102647df909f61301fcc8ec05458dd5881
2013-05-10 20:14:40 -07:00
Craig Mautner
c3797f40c1 am 4754f401: Merge "Avoid NullPointerException in getHandler()"
* commit '4754f401a912305e1ceec04b62ad9b9f7d3c2ff6':
  Avoid NullPointerException in getHandler()
2013-05-10 13:34:23 -07:00
Svetoslav
1e4c658994 am b3c2b21b: Merge "Accessibility should not query for list items when data set changed." into jb-mr2-dev
* commit 'b3c2b21b5ba30d82938ae2ef93d8120f5fd0cc80':
  Accessibility should not query for list items when data set changed.
2013-05-10 13:10:41 -07:00
Svetoslav
b3c2b21b5b Merge "Accessibility should not query for list items when data set changed." into jb-mr2-dev 2013-05-10 20:06:42 +00:00
Chet Haase
a9d5adea9e am fb32c824: Merge "Fix start delay jank in ViewPropertyAnimator" into jb-mr2-dev
* commit 'fb32c82412111983236f44cbc8fd90f113d7ea34':
  Fix start delay jank in ViewPropertyAnimator
2013-05-09 16:23:29 -07:00
Chet Haase
fb32c82412 Merge "Fix start delay jank in ViewPropertyAnimator" into jb-mr2-dev 2013-05-09 22:09:18 +00:00
Chet Haase
dcfbd6a2c9 Fix start delay jank in ViewPropertyAnimator
Issue #8892620 start delay jank in ViewPropertyAnimator

Change-Id: I17a57ac3351fb2c1516b594d135aa9ce9f78c88e
2013-05-09 14:40:21 -07:00
Svetoslav
5b578daac9 Accessibility should not query for list items when data set changed.
AbsListView is backed by an adapter. After the adapter data changes
the view sets a flag that its state is dirty and requests a layout.
If an accessibility service asks for the state of a list item at
this point, it may incur an error since the views and the adapter
are not in sync.

Now if an accessibility service queries for a list item when the
data set is changed and the item views are dirty, we pretend the
children do not exist. After the layout happens, we notify the
accessibility layer that the screen content changed so it can
refetch the views if desired (this notification mechanism is
already in place in AbsListView#handleDataChanged()).

bug:8433433

Change-Id: I4287a0ac2ef6bb33f1f988d5ddad973556c305ca
2013-05-08 14:23:38 -07:00
Michael Jurka
7741b63c5a am 6dee0a0f: Merge "Fix bug where thumbnails flashed more often in Recents" into jb-mr2-dev
* commit '6dee0a0fe68096a6714b7d570241f61e4d6ea20a':
  Fix bug where thumbnails flashed more often in Recents
2013-05-08 14:10:44 -07:00
Michael Jurka
f42d9010f1 Fix bug where thumbnails flashed more often in Recents
Bug: 8867698

Change-Id: I2773601d83507dbb55c3a1d0b723e3853e22d352
2013-05-08 20:48:36 +02:00
Fabrice Di Meglio
6eb036e789 am 366b97ba: Merge "Fix bug #8839681 Reversed Textbox focus order on RTL and android:imeOptions="flagNoExtractUi"" into jb-mr2-dev
* commit '366b97ba25de237c42c815c5e8ca36303ce104df':
  Fix bug #8839681 Reversed Textbox focus order on RTL and android:imeOptions="flagNoExtractUi"
2013-05-08 11:17:25 -07:00
Fabrice Di Meglio
366b97ba25 Merge "Fix bug #8839681 Reversed Textbox focus order on RTL and android:imeOptions="flagNoExtractUi"" into jb-mr2-dev 2013-05-08 17:56:17 +00:00
Alan Viverette
fa4c935edc am 239a0c0e: Ensure ViewRootImpl.setAccessibilityFocus() doesn\'t crash when reentrant.
* commit '239a0c0e6a6fc36025fdb1c662e1c7acaec144bb':
  Ensure ViewRootImpl.setAccessibilityFocus() doesn't crash when reentrant.
2013-05-07 17:43:18 -07:00
Alan Viverette
239a0c0e6a Ensure ViewRootImpl.setAccessibilityFocus() doesn't crash when reentrant.
Internal state must be cleared before calling any methods on the focus
host, since the method may be called again from the host and attempt to
recycle the same AccessibilityNodeInfo twice.

BUG: 8856860
Change-Id: I0410989fd6f3ce3ce29de8edebdfbf3847188843
2013-05-07 17:17:35 -07:00
Fabrice Di Meglio
3167c88c2c Fix bug #8839681 Reversed Textbox focus order on RTL and android:imeOptions="flagNoExtractUi"
- make SequentialFocusComparator RTL-aware

Change-Id: I3d9cc81f777d16933a8e1b69f8ed63efa5be0925
2013-05-07 15:46:22 -07:00
Romain Guy
c4818d860b am 4c95c537: Merge "Optimize list view scrolls Bug #8108706" into jb-mr2-dev
* commit '4c95c5377a75a3d6c5f3ed8b09a56071d51fadb1':
  Optimize list view scrolls Bug #8108706
2013-05-06 19:09:25 -07:00
Romain Guy
5549cb590d Optimize list view scrolls
Bug #8108706

Change-Id: I8679b584132e82b7bb3301a38800de4ddfc57be6
2013-05-06 18:42:08 -07:00
Dave Burke
38996cdcf1 am 236cc476: Temporarily revert field name change (DO NOT MERGE)
* commit '236cc476e6792a11502ba4f40c7ab4586f40d282':
  Temporarily revert field name change (DO NOT MERGE)
2013-05-06 11:11:51 -07:00
Fabrice Di Meglio
a8549041cc am 8c2e3a41: Merge "Optimize RTL properties resolution" into jb-mr2-dev
* commit '8c2e3a412aaee8359a48265a101ca27e7b67301c':
  Optimize RTL properties resolution
2013-05-06 11:11:03 -07:00
Dave Burke
236cc476e6 Temporarily revert field name change (DO NOT MERGE)
VisualOn is using hidden fields, causing HBO and Xfinity to crash.
Bug: 8549617
Bug: 8331866

Change-Id: I35a9fe66dea8d56f4fcff9b492679226a17f4acc
2013-05-06 00:21:30 -07:00