Expose this method so that subclasses can declare new types of services
that can be returned by getSystemService(Class<T>).
Bug: 21343770
Change-Id: I08bdfa61153d19298645dc495deb2d535e54f9f0
Previously we used time in foreground as our sole signal. Now, also
use time since last launch and launch count as signals.
Still to come later: launch count based on specific component name
rather than package, pending the recording of that information in
usage stats.
Change-Id: Ic449cae396cfee797b7bb3de9dc3c0da5da2f96c
Improve wording of javadoc for nextSpanTransition() to accurately
reflect the actual implementation.
Bug: 19274845
Change-Id: I8f8fb6a21a8cbcc26fefb63164a6943431d16089
We used to only remove requests that we'd acted on but that's
just wrong.
Also adds test case which exposed the problem but passes with the fix.
bug:20731384
Change-Id: I581a005560cc71167b857abf2452769399a9e1b7
Preview surface default format is not ImageFormat.PRIVATE, the check need to
take this into consideration.
Change-Id: Ib99e64f7781dd15cc5634c66b2d5e5ab2a2d7d6c
- Add DocumentsContract.EXTRA_EXCLUDE_SELF (boolean extra)
- Add code to DocumentsActivity to cache the providers of the calling
app if EXTRA_EXCLUDE_SELF is set on incoming Intents.
- Add code to RootsCache to exclude roots from the calling app.
- Add code to allow only system apps to use EXTRA_PACKAGE_NAME.
Change-Id: Ia7cc2a1a297676c7b26f6e583042a4607d8c9a4e
When adb is disabled, the default usb mode would be "none", which
would turn off the driver and prevent UsbDeviceManager from receiving
any new USB connect / disconnect messages. This prevents the user
from ever enabling MTP and sharing data when adb is turned off.
As discussed in bug 21429947, we work around this problem by keeping
the USB driver in MTP mode most of the time, so that we continue to
receive USB connect / disconnect messages.
To avoid leaking confidential user photos, this change introduces an
unlocked state. Setting the mtp enabled function is now decoupled from
exposing data on the USB connection. Only if MTP is enabled and
USB data has been unlocked is confidential user data allowed to be
shared.
Bug: 21429947
Change-Id: Iefb5c7e22dc4962bf5226f2ed3d0155b5c7b413c
Bug: 8012229
mReportNextDraw is set by resized to have updateWindow() do
its thing. However if we are in updateWindow() and the
relayout() call to WindowManager wants us to report the draw
we should set reportNextDraw instead of mReportNextDraw
so that we report that frame instead of at the accidental next
invalidate.
Change-Id: If6c38d95599469831a0bd5e4d2b3f6c4f259e40c
This reverts commit 259292ff3de5b9a64e8e3bb4a62a533aef4125b7.
This introduced another bug (Bug: 21687602) and this is no longer useful
for the original one (Bug: 21178876).
Change-Id: I59acc161e7d8cba633718a3d17292e68740ef79e