32673 Commits

Author SHA1 Message Date
Svetoslav
6b1d5a4ff2 Merge "Notification for changed subtree in accessibility mode not fired properly." 2013-06-10 19:55:39 +00:00
Svetoslav
00dbe81fea Notification for changed subtree in accessibility mode not fired properly.
We fire notifications that the a view subtree changed for accessibility.
In some cases the notifications were fired if accessibility is not
enabled. This is now fixed. Also the runnable for making the recurring
subtree change was not dequeued if it was pending but we received a
request which we decided to run immediately.

bug:9337912

Change-Id: I27401b3d11f81c653e8761a704ee530263b08c3a
2013-06-10 12:51:14 -07:00
Craig Mautner
6a7e5c28a4 Merge "Dismiss immediately to maintain consistent state." 2013-06-10 19:21:27 +00:00
Craig Mautner
92098c7c30 Dismiss immediately to maintain consistent state.
Fix bug introduced by deferring nulling of mParent.

In dismissDialog the removal was being put on a queue while the
state of the Dialog was being updated immediately. This meant that
if a show() was called before the remove was executed it would try
and add the DecorView a second time. Boom!

Fixes bug 9370301.

Change-Id: I576d1e207c786bc2e21dfd40cb94f2b63a020fe2
2013-06-10 11:39:21 -07:00
Romain Guy
f38fd87844 am 7a6e1297: am 8d8fc469: Merge "Don\'t orphan footers with transient state Bug #8725945" into jb-mr2-dev
* commit '7a6e129759672f0c1b0ce462d389c0f469e7348f':
  Don't orphan footers with transient state Bug #8725945
2013-06-10 11:12:09 -07: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
Eino-Ville Talvala
b2675542c2 Initial commit of new camera API, mostly just the interface.
- New core API classes in android.hardware.photography
- android.media.Image and android.media.ImageReader classes for
  application access to direct hardware image buffers.
- Additions to android.graphics.ImageFormat to describe new image
  types needed by new camera API.
- Some documentation included; very little implementation.

Bug: 9111736
Change-Id: I0680f35944d1cb8845b7dc0c67edc8c0f0864573
2013-06-07 21:29:45 +00:00
Romain Guy
81056427e8 Merge "Remove unnecessary Rect, better reuse of NinePatch objects" 2013-06-07 20:14:58 +00:00
Romain Guy
f3187b7df1 Remove unnecessary Rect, better reuse of NinePatch objects
Cloning drawables (which happens a lot) was creating copies of NinePatch
objects, which would cause the hardware renderer to generate more meshes
than necessary. Also avoid keeping a String we don't need (it was interned
but still.) Last but not least, remove 1 RectF per NinePatch in the system.

Change-Id: If4dbfa0c30892c9b00d68875e334fd5c2bde8b94
2013-06-07 12:17:11 -07:00
Adam Powell
a4d04291d4 am 87c79d64: am d3cb6bcf: am 8152c794: Merge "Fix incorrect fragment animation used for hiding fragments"
* commit '87c79d64abeb65468a49729f23c97c7e3b9d7e49':
  Fix incorrect fragment animation used for hiding fragments
2013-06-07 11:56:56 -07:00
Adam Powell
87c79d64ab am d3cb6bcf: am 8152c794: Merge "Fix incorrect fragment animation used for hiding fragments"
* commit 'd3cb6bcf0f63317d1078a2f897d4824ba91402a6':
  Fix incorrect fragment animation used for hiding fragments
2013-06-07 11:52:36 -07:00
Adam Powell
d3cb6bcf0f am 8152c794: Merge "Fix incorrect fragment animation used for hiding fragments"
* commit '8152c7940a10f11a9edb16ae1daeca8a6fe2e6bb':
  Fix incorrect fragment animation used for hiding fragments
2013-06-07 11:49:32 -07:00
Romain Guy
3f5e9e8019 Merge "Avoid Binder call when getting the Window service" 2013-06-07 18:07:18 +00:00
Romain Guy
e50848bfba Avoid Binder call when getting the Window service
Change-Id: Ie4f01838402bec4b387e40ce02a1af7f12941538
2013-06-07 10:57:25 -07:00
Adam Powell
2756293910 Fix incorrect fragment animation used for hiding fragments
Mirror of support lib patch
https://android-review.googlesource.com/#/c/60032/ into
frameworks/base.

Change-Id: I8d1cb2e217721336674b8e3e2ef8722a8d9baefd
2013-06-07 10:19:22 -07:00
Scott Main
20b53f89fa am ad47f8c2: am 00d17f7a: add attributes to accessibility service info
* commit 'ad47f8c2dc31247ce9f504eccf21d50d115129d7':
  add attributes to accessibility service info
2013-06-07 09:46:50 -07:00
Scott Main
ad47f8c2dc am 00d17f7a: add attributes to accessibility service info
* commit '00d17f7aab54ef055d35da603dab5a7bae751876':
  add attributes to accessibility service info
2013-06-07 09:44:18 -07:00
Chet Haase
5133dcb838 Merge "Additional functionality and performance for ArrayMap" 2013-06-07 14:05:46 +00:00
Satoshi Kataoka
65ea41541b Merge "Fix an issue where "SuggestionSpan"s are not removed properly" 2013-06-07 07:59:44 +00:00
Chong Zhang
799d4af8cf Merge "wifi-display: set display to unavailable if p2p device is unavailable" 2013-06-07 03:28:11 +00:00
Scott Main
00d17f7aab add attributes to accessibility service info
Change-Id: I3651544164f718003b8eb1235a7d723f1bcee5be
2013-06-06 18:37:59 -07:00
Svetoslav
494cb689d0 Merge "Optimizing AccessibilityNodeInfo caching." 2013-06-07 00:04:57 +00:00
Chet Haase
f4130cf35f Additional functionality and performance for ArrayMap
Added equals() and hashCode() to ArrayMap to allow equals() tests
of maps with the same key/value pairs to return true.

Changed putAll() to handle the case of an empty map faster, just copying
the arrays instead of adding elements one by one.

Added to ArrayMapTests to test new equals() and copy constructor
functionality.

Issue #9299310 Optimize ArrayMap copy constructor

Change-Id: I1186a0eddd1fd53a0f380c2f3972fc1942cdf879
2013-06-06 16:43:41 -07:00
Chong Zhang
21f603996e wifi-display: set display to unavailable if p2p device is unavailable
Bug 9229799

Change-Id: I680015943f40cded45645dfa0eae42bbce5ce9a3
2013-06-06 15:49:16 -07:00
Jeff Sharkey
7a1c3fce47 Accumulate network statistics based on deltas.
Network stats are now read out of the kernel in one sweep, instead of
reading per-UID.  We now accumulate the delta traffic between each
stats snapshot using the well-tested SamplingCounter pattern.

Since Wi-Fi and mobile traffic have different costs, track each
separately.  Avoids counting misc interfaces like loopback and
ethernet under total.

Bug: 5543387
Change-Id: I642004dc530113c27ef79f2abbae51d8af30117f
2013-06-06 14:35:34 -07:00
Romain Guy
c840a13342 Merge "Remove unnecessary allocations" 2013-06-06 21:02:35 +00:00
Chris Wren
29ee561d2d Merge "reveal the notification extras" 2013-06-06 19:51:47 +00:00
Trevor Johns
a699da6f19 Merge "docs: Fix minor typo in android.content.SyncResult" 2013-06-06 19:49:28 +00:00
Chris Wren
da76ad2ea3 reveal the notification extras
Change-Id: Ic97e3485dc23eeb5cfb565a5cef98489acdec8a2
2013-06-06 15:34:21 -04:00
Romain Guy
f69913056b Remove unnecessary allocations
Change-Id: Ia561a0a312ca2737d5afa742184f5392bb2f29a3
2013-06-06 12:10:42 -07:00
Chet Haase
e2b66ff085 Merge "Fix CrossFade transition" 2013-06-06 17:37:10 +00:00
Chet Haase
71ce4876e5 Merge "Fix crash with LayoutTransition and ViewOverlay collision" 2013-06-06 17:35:24 +00:00
Craig Mautner
d0d3ca9548 Merge "Replace arrays with ArrayList" 2013-06-06 15:33:03 +00:00
Craig Mautner
8306f87132 Merge "Delay removal of windows from WindowManager" 2013-06-06 15:31:32 +00:00
Craig Mautner
652fdfaf6f Replace arrays with ArrayList
The three arrays were being reconstructed and copied for each add
and each remove. By replacing them with ArrayList only three
constructions total are required. Also, the number of
System.arraycopy() calls is halved.

Change-Id: I0f8def1b517eb1bc5f930fcd5d3d1e0394071f0e

Conflicts:
	core/java/android/view/WindowManagerGlobal.java
2013-06-06 07:51:57 -07:00
Chet Haase
4f0c4672ac Fix CrossFade transition
Small fixes in CrossFade to handle more general situations.
Also, added API to CrossFade to enable different behaviors during
the transition.

Change-Id: I12d17ab8f8f96be370c070373112ad8a62df9115
2013-06-06 07:37:32 -07:00
Craig Mautner
05eb730ca4 Delay removal of windows from WindowManager
When relaunching activities the window manager clears out all windows
by calling a ViewRootImpl.die() in a deferred fashion. Then it
immediately deletes the ViewRootImpl and its view from its list
of windows. When the die() is eventually executed it calls
dispatchDetachedFromWindow() which tries to remove the previously
removed windows causing an Exception to be thrown.

This change waits to remove the windows until after die() has been
completed. Fixes bug 8253030.

Change-Id: I5b41be1c6b776e32128c064267653db98bd95292
2013-06-06 07:32:13 -07:00
Chet Haase
ce08ce539a Fix crash with LayoutTransition and ViewOverlay collision
When a View is added to a ViewGroupOverlay, it must not be parented
in another container. If it is, it will automatically be removed.
This works in general, but if there is a LayoutTransition on the
view's parent, then the actual removal will be delayed until the
transition completes. This means that the call to add(view) in
the ViewGroupOverlay's container will fail and throw an exception because
the view is still parented for the duration of the LayoutTransition.

This fix cancels the running transition to ensure that the view is not
parented prior to adding it to the overlay's container.

Issue #9303245 Crash combo: add(View) and animateLayoutChanges

Change-Id: Id4eaddccf64c353fc77e020882b978cdeb14c0ef
2013-06-06 07:27:53 -07:00
Trevor Johns
05d60beb89 docs: Fix minor typo in android.content.SyncResult
Change "storage later" to "storage layer" in docs for
SyncResult.databaseError.

Change-Id: I5fa07c2e58c65dbe00b1341f0cca99d47d2dd264
2013-06-05 19:23:50 -07:00
Elliott Hughes
e7af0d2866 am 340df6c4: am 4d33a8ab: am fa6d6256: Merge "change "next" to "done" in minute IME option under 24-hour format"
* commit '340df6c4f7af79dc085471064211ba01ebd45f0a':
  change "next" to "done" in minute IME option under 24-hour format
2013-06-05 16:29:13 -07:00
Elliott Hughes
340df6c4f7 am 4d33a8ab: am fa6d6256: Merge "change "next" to "done" in minute IME option under 24-hour format"
* commit '4d33a8aba33fa70e1e1a1c713e487a26a090bc25':
  change "next" to "done" in minute IME option under 24-hour format
2013-06-05 16:26:04 -07:00
Elliott Hughes
4d33a8aba3 am fa6d6256: Merge "change "next" to "done" in minute IME option under 24-hour format"
* commit 'fa6d6256e9052a5f5155ac97364170f6518e37a4':
  change "next" to "done" in minute IME option under 24-hour format
2013-06-05 16:23:34 -07:00
Elliott Hughes
fa6d6256e9 Merge "change "next" to "done" in minute IME option under 24-hour format" 2013-06-05 23:20:37 +00:00
Svetoslav
6254f4806d Optimizing AccessibilityNodeInfo caching.
1. Before we were firing an accessibility event from the common
   predecessor of views with accessibility related state changes
   every X amount of time. These events designate that the tree
   rooted at the source is invalid and should not be cached.
   However, some of the state changes do not affect the view tree
   structure and we can just refresh the node instead of evicting
   and recaching nodes infos for views that did not change. Hence,
   we need a way to distinguish between a subtree changed over a
   node changed.

   Adding a new event type will not work since if say two siblings
   have local changes and their predecessor fires a window state
   change event, the client will drop the subtree rooted at the
   parent including the two views with changes. Subsequent, more
   specialized events emitted from the two changed siblings will
   be useless since the parent which did not changed is already
   evicted from the cache. Conversely, if the specialized events
   are fired from the two siblings with local changes and they
   are refreshed in the cache the subsequent window state change
   event from the common predecessor will force the refreshed
   nodes to be evicted.

   Hence, to enable distinction between node being changed and
   a subtree baing changed while not changing existing behavior,
   we will fire only window content change event with an additional
   argument specifying what changed - node or a subtree for now.
   Also if the changes are local to a view we fire the window
   content changed event from the view. So, the two siblings will
   fire such an event independently and the client will know that
   these are local changes and can just refresh the node. If the
   changes are structural, then we fire the window state change
   event from the common predecessor.

2. Added the input type of a text view as one of the properties
   reported by an AccessibilityNodeInfo. It is nice to prompt the
   user what input is expected.

3. Added a bundle for optional information to AccessiiblityNodeInfo.
   For example, it will be used for putting web specific properties
   that do not map cleanly to Android specific ones in WebView.

4. AccessibilityInteractionController was not taking into account
   whether the current accessibility focused node is shown before
   returing it. Hence, a disconnected node would be returned and
   caching it puts our cahche in an inconsistent state.

Change-Id: I8ed19cfb4a70bdd7597c3f105487f1651cffd9e0
2013-06-05 15:16:05 -07:00
Scott Main
436a1c651a am 63fcfd5a: am 06543a45: small cleanup of trigger event javadoc
* commit '63fcfd5a52090542e5da601336f712ee64e61d8a':
  small cleanup of trigger event javadoc
2013-06-05 14:44:20 -07:00
Scott Main
63fcfd5a52 am 06543a45: small cleanup of trigger event javadoc
* commit '06543a4559b34abf91e34cb44438683e77e7db36':
  small cleanup of trigger event javadoc
2013-06-05 14:41:51 -07:00
Scott Main
06543a4559 small cleanup of trigger event javadoc
Change-Id: Ib8a0fc0a7ddac6259cc1bb9e8701b0d570a101c6
2013-06-05 14:29:50 -07:00
Romain Guy
ba23e80b80 Merge "Remove string allocations when creating display lists" 2013-06-05 21:15:03 +00:00
Romain Guy
450dc7554d Remove string allocations when creating display lists
Change-Id: Id520db981a3988cb980c8da5dbea8f26ef94989f
2013-06-05 14:14:03 -07:00