FLAG_ACTIVITY_CLOSE_SYSTEM_DIALOGS was a mistake.
Instead, and the infrastructure for the status bar to take care
of closing and hiding things itself when you press these buttons,
just like it does for the main Intent of the notification.
Bug: 6717667
Change-Id: I1b22186e0cedc05f46a1a3ec78053a72afaf61b1
This class does not offer any advantages over SQLiteStatement
and just makes code more complex and error-prone.
Documented that the class is not thread-safe.
Removed a potential deadlock in insert() and replace() caused
by the insertInternal() method being synchronized in the case
where the class was being used concurrently (woe to you!).
Thread A would start a transaction.
Thread B would call insertInternal() and acquire the object monitor,
but block because it could not obtain the db connection because
thread A is holding onto it.
Thread A would call insertInternal() and block because Thread B
was holding the object monitor.
Deadlock.
Changed this code to use a transaction instead of a lock,
which provides the necessary mutual exclusion guarantee without
the potential for a deadlock. Even so, the class really isn't
thread safe.
Bug: 6625094
Change-Id: I51d9a15567a6f2bad6f25e550b48f8f6ffcab2a7
Allow applications to set a requested volume level on RouteInfo
objects. If requested for a user route, the app-supplied callback will
be invoked to perform actual volume adjustment.
Change-Id: I856990a0da7292492aa15e6562dbc3d055b848a0
Mostly just moved the code around and improved the docs.
Fixed a minor inefficiency in WakeLock.setWorkSource() where
we would tell the power manager that the work source was changed
even when the old work source and new work source were both null.
Fixed a bug in WakeLock.setWorkSource() where we would not
notify the power manager that the work source was changed if
there was no work source previously specified.
Added synchronized to WakeLock.setReferenceCounted.
Added a checked in WakeLock.acquireLocked() and WakeLock.release()
to check whether the wake lock is actually not held / held
before performing the corresponding operation. This change avoids
making redundant calls into the power manager service in the
case where the wake lock is not reference counted and acquire()
or release() have been called multiple times.
Made the PowerManager and WakeLock classes final. They are not
directly instantiable by applications so this change does not
break the API.
Removed a little dead code (one private constructor and an
unused constant).
Change-Id: I4e10cf893506115938a35756136c101256dccf30
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
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
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
This also includes a previous change to current.txt that hasn't been
copied to 16.txt yet
Bug:6662259
Change-Id: Iaab5c38ad56882a1270b5276ba7a399bbb8a49f3
* 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
1. Currently we are providing accessibility focus search algorithm in the
framework and we are also setting accessibility focus from hover. It
appears that implementing a focus search strategy that works for all
accessibility services is non trivial task if feasible. Based on
feedback from the developers of two such services at Google - TalkBack
and BarilleBack - the built in focus search does not quite match what
they need and they would like to implement a custom strategy.
Hence, having APIs for accessibility focus search in the framework does
not make. Therefore, we are hiding this APIs and later will take out the focus
search logic and allow the accessibility service to implement search.
Also putting accessibility focus from hover is tightly integrated with
the focus search since the set of views that get accessibility focus
from hover should be the same as the set of views returned by the
focus search routine. Therefore, we are letting the accessibility service
decide where to put accessibility focus when it gets an accessibility
hover event.
bug:6675330
Change-Id: Ie152230990a6602f3fd1d82de2177d0b1444d654