1. Adding bundle with metadata to PrintDocumentAdapter#onLayout
with one key for now to specify whether this is for a preview.
2. Cleaned up docs.
Change-Id: I89380781bf3ae41aa89f8a0347d74516a210394c
The default Alarm Manager behavior for KLP+ apps will be to aggressively
coalesce alarms, trading exact timeliness of delivery for minimizing the
number of alarm-delivery points, especially wakeup points.
There is new API in AlarmManager, setExact() and setExactRepeating(),
for use by apps that absolutely *must* get their alarms at a specific
point in time.
Bug 9532215
Change-Id: I40b4eea90220211cc958172d2629664b921ff051
bug:9797004
Grants a means to reuse a bitmap's allocation for different
width/height/Config without going through
BitmapFactoryOptions.inBitmap
Change-Id: Ib62319f3bd96c451fc1636288adf06a8275b4e3d
This new method on view reflects whether the view has been laid out
at least once since it was attached. hasLayout() seems too vague for that
meaning; every View that has a parent has a layout (since we use container,
parent, and layout interchangeably). The new version of the method
is closer to the actual meaning.
Change-Id: I519745739b6a6317faeb077aa61f994025cf81f3
Also do some tweaking of the various container classes
to synchronize them with the support lib and make it
easier to copy code between the two.
And update activity/fragment to use ArrayMap.
Change-Id: I3cfe82392a17119dfc72c3d9961f64e1914f42be
If a window's task stack has no sibling, restore old behavior
of allowing frame to go below the nav bar.
Bug:9884905
Change-Id: Ifc38901a6633cf431dba8740a65258d0618c0fd0
This change introduces a new measure cache to View, to remember
the measured dimensions for previous pairs of measure specs. The
measure cache is cleared whenever a View requests layout.
Unfortunately some Views rely on measure being always called when
layout is invoked. To work around this problem, we need to remember
when we hit the measure cache to force a call to measure just prior
to calling onLayout(). This does not completely removes all measure
calls but enough to optimize a number of layouts.
Change-Id: Ie085fbcf186e9d7505e1127e0786a12968ebc344
The display wake lock and other internal state could become
out of sync if we happened to execute the power manager's update
function concurrently due to the missing lock.
This bug can be trigged due to display state changes or proximity
sensor updated. Although it would be extremely rare, we have
some evidence of this happening on at least a few devices resulting
in rapid power drain with the screen off or a crash.
Bug: 9880044
Change-Id: I3c674ce429621a50cbb36c3a01883d5f388205b2
Previously, there were two distinct problems with how delayed
transitions were being run:
- there would be a delay between the transition being put into
a preDrawListener (to be kicked off when that listener fired) and
being removed from the pending list. This allowed another delayed
transition to be run in parallel, which would cause conflicting/
clobbering issues with transition values on the same objects.
- there would be an extra frame delay in some cases due to how/when the
delayed transition would be started. Specfically, we would postOnAnimation()
to call a method that would then add the onPreDraw listener. This two-step
forwarding caused issues noted above.
The fix is to simply add the transition to the preDrawListener immediately, removing
the two-step problem, and also ensuring that the transition is only removed
from the pending list when it is actually started, which prevents other transitions
from starting in the meantime.
Also, added more debug logging to help chase future issues with transitions.
Change-Id: Ie2ff8e73d29f342512842e9641bd8d605e74544c
setMatrix() was crashing in native code, only with hw acceleration on.
concat() would throw a NullPointerException. It now ignores null matrices.
Change-Id: Iebd8b410a957d2ba501570c6fbb3f680ff4a1a23
1. Fixed a case in which the onPrintCompleted callback may not be invoked.
2. Added string resulrces for the different error messages for failed
printing in OnPrintCompletedCallback
3. Fixed the string comments for the MediaSize constants.
4. Added APIs to create certain print attributes by passing in a
string label instead of resource and package name since in some cases
a print service may be getting already internationalized lables
or it may not know all possible values.
5. Fixed a crash in PrintJobConfigActivity if there is no input or
output tray.
Change-Id: Ie877b7dc669051606394aa290e6d2b979a42db4c
Remove DisplayContentsIterator and AllWindowsIterator. These were cute
but they take up valuable resources. Iterate over ArrayList members
in their place.
Change-Id: I1d8a3b040175cb88b98f6a7e97cab06d17d5706b
1. Now a user state has ins own spooler since the spooler app is
running per user. The user state registers an observer for the state
of the spooler to get information needed to orchestrate unbinding
from print serivces that have no work and eventually unbinding from
the spooler when all no service has any work.
2. Abstracted a remote print service from the perspective of the system
in a class that is transparently managing binding and unbinding to
the remote instance.
3. Abstracted the remote print spooler to transparently manage binding
and unbinding to the remote instance when there is work and when
there is no work, respectively.
4. Cleaned up the print document adapter (ex-PrintAdapter) APIs to
enable implementing the all callbacks on a thread of choice. If
the document is really small, using the main thread makes sense.
Now if an app that does not need the UI state to layout the printed
content, it can schedule all the work for allocating resources, laying
out, writing, and releasing resources on a dedicated thread.
5. Added info class for the printed document that is now propagated
the the print services. A print service gets an instance of a
new document class that encapsulates the document info and a method
to access the document's data.
6. Added APIs for describing the type of a document to the new document
info class. This allows a print service to do smarts based on the
doc type. For now we have only photo and document types.
7. Renamed the systemReady method for system services that implement
it with different semantics to systemRunning. Such methods assume
the the service can run third-party code which is not the same as
systemReady.
8. Cleaned up the print job configuration activity.
9. Sigh... code clean up here and there. Factoring out classes to
improve readability.
Change-Id: I637ba28412793166cbf519273fdf022241159a92
Fix a regression caused by a previous overzealous refactoring. (Oops.)
Watch those conditionals, everyone!
Bug 9866559
Change-Id: Ia88a4ee38edef378e70bdc7151c825375a3d482d
inflateViews() and updateNotification() reference the same objects
with different names, and it was confusing. #cleanup
Bug: 6497005
Change-Id: I0d9a94d7ec156b6bfcf4b85c777f9b58311d07d0
Move markSocketAsUser to the top of IConnectivityManager.aidl to make
calls from
framework/native/services/connectivitymanager less fragile
Change-Id: Iba92c21dfef175b570521f34e7ee2732e5a0a9c9