32177 Commits

Author SHA1 Message Date
Jean-Michel Trivi
3114ce3861 Remote volume handling
Extend RemoteControlClient class to enable an applicaton to
 specify more information about how it's playing media, now covering
 usecases where media playback happens "remotely". This playback
 information can be used to set the volume and maximum volume
 used remotely.
Declare a new intent and associated extras in Intent,
 ACTION_VOLUME_UPDATE, so an application can be notified that
 the volume it handles should be updated. It can then use
 the new RemoteControlClient.setPlaybackInformation() method
 to notify AudioService what the volume is.
Extend AudioService to maintain playback information associated
 with the RemoteControlClient information in the stack of
 media button event receivers (mRCStack). The information
 about the active remote is cached so the stack doesn't have
 to be iterated over in order to retrieve remote playback info.
 Events to "adjust" the remote volume based on hardware key
 presses cause the client application to be notified of
 volume updates, and the volume panel to display the volume
 set by the app.
 Revise which stream type is controlled when none is specified
 according to latest guidelines for remote playback.
Update VolumePanel class to support a new pseudo stream type,
 AudioService.STREAM_REMOTE_MUSIC, that corresponds to the
 remote playback volume, and uses the new "media route" icon.
 Enable it to receive asynchronously new volume values for
 the remote that will be displayed if the UI is still up,
 and ignored otherwise.
 Now supports hiding/showing sliders dynamically so remote
 volume only appears when AudioService has a remote control
 client handling remote volume.
Define new java symbols for the two media route icons.
Modify lockscreen behavior: don't automatically control music
 volume when music is active, consider also remote playback.

Still to do:
- playback information set by RemoteControlClient should post
  a message for AudioService to update playback information
  instead of updating it synchronously

Change-Id: I557aa687239f9acfe33a609f05876c67fa7eb967
2012-06-18 18:37:17 -07:00
Nicolas Falliere
277c09f6c1 am 56bb344c: Merge "Added or fixed doctrings for required permissions." into jb-dev
* commit '56bb344ccfd3d261cea9987c98a17d0820279b17':
  Added or fixed doctrings for required permissions.
2012-06-18 17:42:57 -07:00
Nicolas Falliere
56bb344ccf Merge "Added or fixed doctrings for required permissions." into jb-dev 2012-06-18 17:39:48 -07:00
Jim Miller
60fd2b2de2 am ddbc85cb: Merge "Fix 6683092: tune GlowPadView wave animation" into jb-dev
* commit 'ddbc85cbfdc8ac6ed02b104f0e9c46018a0e1c53':
  Fix 6683092: tune GlowPadView wave animation
2012-06-18 17:23:28 -07:00
Nicolas Falliere
9530e3a22d Added or fixed doctrings for required permissions.
Bug: 6591338
Change-Id: Ia2092f9994854701b5fa1425c371817367ae07ec
2012-06-18 17:22:34 -07:00
Jim Miller
5892e2ec25 Fix 6683092: tune GlowPadView wave animation
This adds some aesthetic changes to the wave animation for GlowPadView:
- wave shape is no longer symmetric
- disable expand in keyguard
- enable expand in SearchPanelView (when mAlwaysTrackFinger == true)
- if a current wave animation isn't finished yet, don't start a new one
- various timing changes

Change-Id: Ibce96f45eb6a94582c694108b99e243fd57b1955
2012-06-18 17:04:58 -07:00
Jim Miller
a10b1a738d am 12da2c5e: Merge "Fix 6665117: ACTION_ASSIST visual improvements" into jb-dev
* commit '12da2c5eeeadd6c23da5d3003d0da3b6b73d5052':
  Fix 6665117: ACTION_ASSIST visual improvements
2012-06-18 13:32:05 -07:00
Jim Miller
12da2c5eee Merge "Fix 6665117: ACTION_ASSIST visual improvements" into jb-dev 2012-06-18 13:29:49 -07:00
Ying Wang
a5bcf81416 am c4947277: Merge "Import translations. DO NOT MERGE" into jb-dev
* commit 'c4947277e821153fc01256a425e4cbbe34a06eda':
  Import translations. DO NOT MERGE
2012-06-18 12:58:59 -07:00
Ying Wang
c4947277e8 Merge "Import translations. DO NOT MERGE" into jb-dev 2012-06-18 12:57:03 -07:00
Ying Wang
e3efec74b3 Import translations. DO NOT MERGE
Change-Id: I0108055d8a3aa31fb8157b43e0f2224fab488642
2012-06-18 12:36:51 -07:00
Svetoslav Ganov
45c4a8df94 am ec7c7ebf: Merge "API for finding accessibility focus in virtual tree not needed." into jb-dev
* commit 'ec7c7ebf01121d17f7a12e827bd77c024eab54e8':
  API for finding accessibility focus in virtual tree not needed.
2012-06-18 11:30:09 -07:00
Svetoslav Ganov
ec7c7ebf01 Merge "API for finding accessibility focus in virtual tree not needed." into jb-dev 2012-06-18 11:27:44 -07:00
Svetoslav Ganov
05fa21fa77 am 4cb3b76c: Merge "Ensure WebViewClassic calls super.onHoverEvent()" into jb-dev
* commit '4cb3b76caa004867bac43f0001072e24bfa8c120':
  Ensure WebViewClassic calls super.onHoverEvent()
2012-06-18 10:36:12 -07:00
Adam Powell
c92aa2e7c9 am 1b4dc0fe: Merge "Volume control in MediaRouter dialogs" into jb-dev
* commit '1b4dc0fe00805f82fb4bb89a97b6b0501e117505':
  Volume control in MediaRouter dialogs
2012-06-18 10:34:32 -07:00
Adam Powell
8f695c525f am 706a8699: Merge "Make MediaRouter UI more robust around route count changes" into jb-dev
* commit '706a8699008ce416a7fbd9a4215726fdb00ee803':
  Make MediaRouter UI more robust around route count changes
2012-06-18 10:34:29 -07:00
Jeff Brown
7947698096 am d7a04de1: Capture window manager\'s last ANR state in bug report.
* commit 'd7a04de16798acc04ec0a89a0c7d9f1cf60d1521':
  Capture window manager's last ANR state in bug report.
2012-06-18 10:34:25 -07:00
Makoto Onuki
df6d3eebba am c4637d3e: Merge "Allow restricting the scope of a phone-filter search" into jb-dev
* commit 'c4637d3efbbeb3e204691da96c357b5fea4ae2f1':
  Allow restricting the scope of a phone-filter search
2012-06-18 10:33:45 -07:00
Adam Powell
bb20575f85 am 130b4572: ActionProvider API update
* commit '130b4572d1f3df702e5b296a655d15a41f6d4c66':
  ActionProvider API update
2012-06-18 10:33:19 -07:00
Adam Powell
772ddc0cf2 am fd4df469: Merge "Remove workaround for bug that was fixed a while ago." into jb-dev
* commit 'fd4df46917c79067416985ac53a3da6b27e8c333':
  Remove workaround for bug that was fixed a while ago.
2012-06-18 10:32:46 -07:00
Jeff Brown
4440d158b8 am 5aa02e20: Merge "Revert "Synthesize fake vsyncs when the screen is off."" into jb-dev
* commit '5aa02e20186a9e30553a8ef0d53d5fad4c0b7597':
  Revert "Synthesize fake vsyncs when the screen is off."
2012-06-18 10:32:39 -07:00
Svetoslav Ganov
11832db437 am 531d5866: Merge "Accessibility focus search and setting it from hover are performed by the client." into jb-dev
* commit '531d5866d8e2529e2ae1c6ef12202119753bec03':
  Accessibility focus search and setting it from hover are performed by the client.
2012-06-18 10:32:16 -07:00
Ying Wang
d18d623fe9 am c1568fea: Merge "Import translations. DO NOT MERGE" into jb-dev
* commit 'c1568feaba9f3c4b9f0fab5fcdf062ecb922fcaa':
  Import translations. DO NOT MERGE
2012-06-18 10:31:51 -07:00
Teng-Hui Zhu
c1d3b23b54 am 2075f2d3: Merge "Notify Java side to start when transition into full screen mode without a reload." into jb-dev
* commit '2075f2d3e486b565c9abd2556d81dfb1449f6efb':
  Notify Java side to start when transition into full screen mode without a reload.
2012-06-18 10:31:16 -07:00
Svetoslav Ganov
4cb3b76caa Merge "Ensure WebViewClassic calls super.onHoverEvent()" into jb-dev 2012-06-18 10:20:42 -07:00
Jean-Baptiste Queru
98e955d295 am 20d6caf8: Merge "Fix issue #13366. Take account of stackFromBottom in computeVerticalScrollOffset()."
* commit '20d6caf8888d4114b6ce79d93c7c9cf903ad8c22':
  Fix issue #13366. Take account of stackFromBottom in computeVerticalScrollOffset().
2012-06-18 09:23:55 -07:00
Adam Powell
1b4dc0fe00 Merge "Volume control in MediaRouter dialogs" into jb-dev 2012-06-17 19:32:22 -07:00
Adam Powell
706a869900 Merge "Make MediaRouter UI more robust around route count changes" into jb-dev 2012-06-17 19:32:07 -07:00
Jeff Brown
d7a04de167 Capture window manager's last ANR state in bug report.
Currently just grabbing the window state but we could grab
other things as part of the last ANR report.

Bug: 6680398
Change-Id: I23aa70907b1bdcb21c8acc556fde196ca790ef6a
2012-06-17 15:55:46 -07:00
Svetoslav Ganov
45a02e0809 API for finding accessibility focus in virtual tree not needed.
1. The function for finding where the accessibility focus in a virtual
   node tree presented by an AccessibilityNodeProvider is not needed
   API since the framework already keeps track of the accessibility
   focused virtual node in order to draw the focus rectangle. This API
   adds unnecessary complexity to developers of AccessibilityNodeProviders.

bug:6675330

Change-Id: I84774686b06a995073a39e45b8ef22f2cd04b773
2012-06-17 15:07:38 -07:00
Adam Powell
4599696591 Volume control in MediaRouter dialogs
MediaRouter dialogs now intercept the volume keys for altering the
current volume. The status icon indicates if the slider/buttons are
currently controlling the local device volume or a remote device's
volume.

Group volume for user routes is handled by using the
RemoteControlClient supplied by the first route in the group.

Change-Id: I40a0d054847ed5acce7a4c3b669487841b4dca15
2012-06-16 17:21:57 -07:00
Adam Powell
39d5c61725 Make MediaRouter UI more robust around route count changes
Improve the API around ActionProvider visibility overriding. Allow the
application to notify whatever is hosting the ActionProvider that
visibility has changed in a way that is friendly to alternate support
library-style reimplementations of MenuItem.

Allow MediaRouter.Callback implementations to add or remove themselves
or other Callbacks during dispatch of callback events.

Make MediaRouteActionProvider track the visibility of corresponding
menu items more accurately.

Change-Id: Ic7ddb6a87c3637904750d2661e4a9fa323b09ea0
2012-06-16 14:49:13 -07:00
Makoto Onuki
c4637d3efb Merge "Allow restricting the scope of a phone-filter search" into jb-dev 2012-06-16 12:34:56 -07:00
Pieter-Jan Vandormael
bbf7b4cdcf Fix issue #13366. Take account of stackFromBottom in
computeVerticalScrollOffset().

Change-Id: I743708ef1ac05e358840f37010de36b7d0c6a346
Signed-off-by: Pieter-Jan Vandormael <ezelspinguin@gmail.com>
2012-06-16 17:11:54 +02:00
Daniel Lehmann
1024de5961 Allow restricting the scope of a phone-filter search
This also includes a previous change to current.txt that hasn't been
copied to 16.txt yet

Bug:6662259

Change-Id: Iaab5c38ad56882a1270b5276ba7a399bbb8a49f3
2012-06-15 20:32:33 -07:00
Adam Powell
130b4572d1 ActionProvider API update
* Add ActionProvider#overridesItemVisibility and isVisible.
  These methods allow an ActionProvider to override the
  visibility of a MenuItem that it is bound to. If a MenuItem
  has been explicitly hidden by the application, it will not
  be visible.

* Change MediaRouteActionProvider to not require a MediaRouter
  callback, to avoid extra lifecycle management headaches.

Change-Id: I606fa98b3a6a3e60a953dd024274f9bf9c67acdd
2012-06-15 20:19:29 -07:00
alanv
eebebc9ff6 Ensure WebViewClassic calls super.onHoverEvent()
Bug: 6679763
Change-Id: I9b182f25fa1c4050ea3a046c896e82ffbb4651ad
2012-06-15 18:59:11 -07:00
Jim Miller
20039ad17b Fix 6665117: ACTION_ASSIST visual improvements
- add generic icon for search providers that don't supply one
- change alpha weighting factor for glow
- don't show ring background

Change-Id: I86c86dc2d623c25ec7b91e206fac8ad9cd60faac
2012-06-15 18:11:00 -07:00
Kenny Root
535d3b3f33 am 0cf34218: Merge "Adding test cases for getInstalledPackages"
* commit '0cf342184e030ee6f65d87eeba48484725910a8b':
  Adding test cases for getInstalledPackages
2012-06-15 16:43:29 -07:00
Kenny Root
0cf342184e Merge "Adding test cases for getInstalledPackages" 2012-06-15 16:22:36 -07:00
Adam Powell
fd4df46917 Merge "Remove workaround for bug that was fixed a while ago." into jb-dev 2012-06-15 15:32:14 -07:00
Jeff Brown
5aa02e2018 Merge "Revert "Synthesize fake vsyncs when the screen is off."" into jb-dev 2012-06-15 15:30:40 -07:00
Gilles Debunne
cd943a7a01 Fixed text rendering issue with spans.
Bug 6598784

The algorithm uses three imbricated loops:
- paragraphs
- span regions (called "blocks" in that description) in these
- characters in these

We can ignore the paragraphs and assume paraStart==0.

The span region loop cuts the text into blocks of text which share
the same set of MetricAffectingSpan spans applied to them. Note that
spanStart and spanEnd represent such a range, and not necessarily an
actual span range.

The third loop then iterates over the characters of these blocks, and creates
a new line (calling out() as soon as the width has been reached.

The core of the problem comes from the 'nextSpanStart' variable.
It is used to restart the block loop from a previous position in case
a line has been created that does not intersect with the current block.

However, in case the current block is larger than the width of the text,
the character loop is going to create other lines of text before we exit the
j-loop. Going back to the block loop, we reset spanStart to the nextSpanStart,
which may be too far back in the text. As a result, the same range of characters
is measured again.

The (spanStart == spanEnd) test was used to handle the case where
nextSpanStart was indeed assigned to a value different than spanEnd.

This fix simplifies this logic and removes the nextSpanStart variable:

When the created line ends before the current block (here < spanStart), we
immediately exit the character loop, re-starting the block loop from the
current position.

Patch 4: added a fix in measured to handle overlapping character ranges.

Change-Id: Ie71b3cf4018b332e335ea916fef08acb43a6679e
2012-06-15 15:29:13 -07:00
Adam Powell
307c5cfcdd Remove workaround for bug that was fixed a while ago.
Change-Id: I368dd8fea6b33af6908b6fe3b7691104166a707a
2012-06-15 15:19:09 -07:00
Svetoslav Ganov
531d5866d8 Merge "Accessibility focus search and setting it from hover are performed by the client." into jb-dev 2012-06-15 15:00:43 -07:00
Ying Wang
c1568feaba Merge "Import translations. DO NOT MERGE" into jb-dev 2012-06-15 14:19:08 -07:00
Teng-Hui Zhu
2075f2d3e4 Merge "Notify Java side to start when transition into full screen mode without a reload." into jb-dev 2012-06-15 13:57:28 -07:00
Ying Wang
249405253d Import translations. DO NOT MERGE
Change-Id: I6ab3489fe984c442dceaef41e76ee5e6783e65ef
2012-06-15 12:44:39 -07:00
Adam Powell
15635728a4 am 27db797e: Merge "Update MediaRouteChooserDialog grouping UI" into jb-dev
* commit '27db797e37ea16ea5db6eb3f6a32e0f116c1b824':
  Update MediaRouteChooserDialog grouping UI
2012-06-15 11:54:42 -07:00
Adam Powell
27db797e37 Merge "Update MediaRouteChooserDialog grouping UI" into jb-dev 2012-06-15 11:52:10 -07:00