5529 Commits

Author SHA1 Message Date
Michael Wright
f46b5d466d Misc. buttons aren't gamepad keys.
BUTTON_[1-9] are intended to be misc. buttons so the kernel will
assign them to non-gamepad devices.  As such, we shouldn't treat them
as belonging to gamepads at all.

Bug: 13432364
Change-Id: I9495760f2379e44785b9ce1cf018b6db7f6cb0f4
2014-04-01 15:43:43 -07:00
John Reck
0d1f634f4b Add invokeFunctor
Change-Id: I09e675d3e02e3e528642175ada00b2b17fab7652
2014-03-28 20:57:32 -07:00
John Reck
c75db8266b Merge "Remove kStatusInvoke & kStatusDraw" 2014-03-29 01:41:50 +00:00
Michael Wright
4669cfff1e am d020fd33: Merge changes Ib18c99b9,I9f42eeb9 into klp-modular-dev
* commit 'd020fd33d147c88a9cda4976d2fa559e55b4ab03':
  Generate and respect ACTION_CANCEL for joystick fallbacks. DO NOT MERGE
  Adds API for determining confirm and cancel keys.
2014-03-29 00:59:46 +00:00
John Reck
750ca6dbdb Remove kStatusInvoke & kStatusDraw
They are unused

Change-Id: I44ecf1164dc6bc1b09438e733976d5a97a25f00e
2014-03-28 16:43:15 -07:00
Chris Craik
b265e2ca50 Support shadows on the root RenderNode
bug:13211941

Cleans up some of the RenderNode method naming

Also removes unnecessary clip/save/restores, clipping shadows
predictably, as drawn by the parent, before drawing (and clipping,
etc.) the shadow casting child.

Change-Id: I795115e1fb869bbbdd7be43e279b97490fecc7e0
2014-03-28 14:43:22 -07:00
Chris Craik
08c96b5515 Merge "Disable shadow overdraw avoidance in the inverse clip case" 2014-03-28 18:00:03 +00:00
Chris Craik
024433f896 Disable shadow overdraw avoidance in the inverse clip case
The caster is effectivly transparent, so skip the optimization just as
is done for alpha < 1.0

Change-Id: I3d294222adf0137e20c1fb5808313d487e92e0a8
2014-03-27 16:01:04 -07:00
John Reck
07b6c552e6 Merge "Async drawing!" 2014-03-27 17:11:31 +00:00
John Reck
668f0e38ef Async drawing!
Change-Id: I7e728356f58af88174328a8c0b90d27b128bfe01
2014-03-27 10:00:04 -07:00
Narayan Kamath
ecd072161e resolved conflicts for merge of 22d07464 to master
Change-Id: Ic037261eedd6e224938c960d2b4597590c81ed9d
2014-03-27 14:22:47 +00:00
Narayan Kamath
22d074643e resolved conflicts for merge of eaab4df0 to klp-modular-dev-plus-aosp
Change-Id: I871431e5a3ce45a33563ced845e044d37471689b
2014-03-27 12:50:58 +00:00
Narayan Kamath
eaab4df0dd am cd3f60f3: Merge "AArch64: Make frameworks/base code more portable"
* commit 'cd3f60f30366a34b4499aab5a47b622069ba9cd6':
  AArch64: Make frameworks/base code more portable
2014-03-27 12:36:10 +00:00
Ashok Bhat
f5df700e6c AArch64: Make frameworks/base code more portable
Changes in this patch include

[x] Use %zu for size_t, %zd for ssize_t

[x] Some minor changes have been done to conform with
    standard JNI practice (e.g. use of jint instead of int
    in JNI function prototypes)

Change-Id: Id1aaa7894a7d0b85ac7ecd7b2bfd8cc40374261f
Signed-off-by: Ashok Bhat <ashok.bhat@arm.com>
Signed-off-by: Craig Barber <craig.barber@arm.com>
Signed-off-by: Kévin PETIT <kevin.petit@arm.com>
Signed-off-by: Marcus Oakland <marcus.oakland@arm.com>
2014-03-27 12:30:42 +00:00
Michael Wright
1b10869f39 Generate and respect ACTION_CANCEL for joystick fallbacks. DO NOT MERGE
Also change MotionEvent.PointerCoords bit packing and unpacking
methods to be consistent with BitSets which are now used on the
native PointerCoords object.

Bug: 11480300
Change-Id: Ib18c99b94ac555104c69eac526860aa501e89e03
2014-03-26 14:56:07 -07:00
Chris Craik
62828dfca2 Merge "Add private circular reveal API on View/RenderNode" 2014-03-26 17:40:32 +00:00
Chris Craik
8c271ca63b Add private circular reveal API on View/RenderNode
Change-Id: I139c8e12b354083149a665f6768f3f6931a8dd15
2014-03-25 16:03:48 -07:00
Chris Craik
e08f166955 am 72cf99ab: am 7e55b35a: am 4118480a: am 80470cdf: Merge "Solve three memory leaks related to PatchCache"
* commit '72cf99abdb6648f9346b72e0ef6d4da3c4dc9d17':
  Solve three memory leaks related to PatchCache
2014-03-25 21:23:52 +00:00
Chris Craik
72cf99abdb am 7e55b35a: am 4118480a: am 80470cdf: Merge "Solve three memory leaks related to PatchCache"
* commit '7e55b35a603fe64e8db2c6050a1b778baaccd920':
  Solve three memory leaks related to PatchCache
2014-03-25 20:36:15 +00:00
Chris Craik
7e55b35a60 am 4118480a: am 80470cdf: Merge "Solve three memory leaks related to PatchCache"
* commit '4118480aabb4a7b332e289ebb71d2e4f9bc05d7e':
  Solve three memory leaks related to PatchCache
2014-03-25 20:28:00 +00:00
Chris Craik
6fe434a41b am 4118480a: am 80470cdf: Merge "Solve three memory leaks related to PatchCache"
* commit '4118480aabb4a7b332e289ebb71d2e4f9bc05d7e':
  Solve three memory leaks related to PatchCache
2014-03-25 20:27:52 +00:00
Chris Craik
4118480aab am 80470cdf: Merge "Solve three memory leaks related to PatchCache"
* commit '80470cdf6c6995f4afe8d5e2c4b6e898625173fb':
  Solve three memory leaks related to PatchCache
2014-03-25 13:21:01 -07:00
Adam Lesinski
de898ff429 Shared library resource support
Shared libraries can now export resources for applications
to use.

Exporting resources works the same way the framework exports
resources, by defining the public symbols in res/values/public.xml.

Building a shared library requires aapt to be invoked with the
--shared-lib option. Shared libraries will be assigned a package
ID of 0x00 at build-time. At runtime, all loaded shared libraries
will be assigned a new package ID.

Currently, shared libraries should not import other shared libraries,
as those dependencies will not be loaded at runtime.

At runtime, reflection is used to update the package ID of resource
symbols in the shared library's R class file. The package name of
the R class file is assumed to be the same as the shared library's
package name declared in its manifest. This will be customizable in
a future commit.

See /tests/SharedLibrary/ for examples of a shared library and its
client.

Bug:12724178
Change-Id: I60c0cb8ab87849f8f8a1a13431562fe8603020a7
2014-03-25 12:09:56 -07:00
John Reck
bcad68ad80 Merge "Move where updateProperties is called" 2014-03-25 17:46:18 +00:00
John Reck
632717e609 Merge "Add missing null check" 2014-03-25 17:25:33 +00:00
John Reck
5bf11bb98f Add missing null check
Bug: 13635394
 mDisplayListData can be null, make sure
 to check for that before trying to walk through the
 children list in updateProperties

Change-Id: I8d97b1656c1acf47b7c5df8a8771b0f30907261d
2014-03-25 10:22:09 -07:00
John Reck
bfb07a0377 Move where updateProperties is called
Change-Id: I27da448996019094c44487ce28c5689d098d6535
2014-03-24 21:00:18 -07:00
Jens Gulin
6056e10271 Solve three memory leaks related to PatchCache
A Patch can be fairly large, holding bitmap data, but
is also frequently leaked which adds to the severity.
The feature is used in many important processes such
as Home, SystemUI and Chrome.

The following leaks are solved:

1. The Patch itself was not always freed.
PatchCache::removeDeferred() can mark patches to be
cared for by PatchCache::clearGarbage(). But
mCache.remove() would only destroy the container
and the pointer, not the Patch object itself.

2. The vertices stored in the Patch at Patch::createMesh()
would always leak. The empty/default destructor in Patch
would not properly destroy "vertices" since it's just a
pointer.

3. A BufferBlock that's added to the mFreeBlocks
in PatchCache could leak. The leak happened when a
patch later needed the entire free block, because the
object was removed from the list but never deleted
in PatchCache::setupMesh().

Change-Id: I41e60824479230b67426fc546d3dbff294c8891f
2014-03-25 09:37:02 +09:00
John Reck
78ce1c5247 Add back clobbered cleanup
Change-Id: I418b612710850bbc3033c4bd0143fb0f0befd2cb
2014-03-24 15:43:49 -07:00
John Reck
d0a0b2a314 Add stagingProperties
Change-Id: Ic7de551f8843fd70a77f738e33028e25c020bb3c
2014-03-24 15:31:34 -07:00
Chris Craik
b49f446c98 Rework Outline API, remove isolatedZVolume remnants
Change-Id: I30c2fe832dcb98fa6329b1a595b3d3aafbdcad6b
2014-03-24 11:37:06 -07:00
ztenghui
32ff540c74 Merge "Early rejection on shadows which are outside of the clip bound." 2014-03-20 22:30:59 +00:00
ztenghui
af6f7ed8dd Early rejection on shadows which are outside of the clip bound.
All the computations are estimated using bounding box.
TODO: Spot shadow could have more accurate but also more expensive methods, we need
more experiments to decide.

Change-Id: I9c10c419576cee55daf0f9f278b0db78cb847447
2014-03-20 15:25:47 -07:00
Leon Scroggins III
2488727a59 Update framework to use M33 Skia. DO NOT MERGE
(These CLs are already in master.)

Bug: 13246311

This cherry-picks 7 CLs:

-----------------------------------------------------------------------

Remove calls to deprecated SkBitmap::setIsOpaque()

setIsOpaque() has been removed from ToT Skia.

Update setters for mIsPremultiplied and hasAlpha to take the
other into consideration.

cherry-pick from: I1b36b0b0ce7126031eb7b769b563c17dcd4b306a

-----------------------------------------------------------------------

Merge AssetStream with AssetStreamAdaptor.

Add enums to the constructor for AssetStreamAdaptor to choose the
different behaviors used by the (former) two different classes.

The old clients of AssetStream now get the following features of
AssetStreamAdaptor
- Debugging statements on error.
- The stream is an SkStreamRewindable.
- getLength() returns the correct value, and the old way of getting
  the length (read(NULL, 0)) is no longer implemented, since it is
  no longer used.
- isAtEnd() returns the correct value. ToT Skia makes it pure virtual,
  so some implementation is necessary.

cherry-pick from: I2a5395914e4f53830aaefee396556459083a1c56

-----------------------------------------------------------------------

Deprecate Android-specific SkPaint functions.

The following functions were problematic:
 const SkGlyph& getUnicharMetrics(SkUnichar, const SkMatrix*);
 const SkGlyph& getGlyphMetrics(uint16_t, const SkMatrix*);
 const void* findImage(const SkGlyph&, const SkMatrix*);

Replacing them with calls through SkGlyphCache solved a nasty crash
bug, so they have all been deprecated.

Bug: 11968757
cherry-pick from: Id746315d41aec5b211b78b172a883c2061130f08

-----------------------------------------------------------------------

pass SkGlyphCache into updateGlyphCache()

Doing so prevents us from double-locking the glyph cache, thereby
effectively locking ourselves out of reusing work that we'd just done.

Bug: 11968757
cherry-pick from: I5c552f2d0bbe30af2ce9054ba684e7da756a0d89

-----------------------------------------------------------------------

Updates to the Skia API needed to merge the WebView m33 version of Skia.

cherry-pick from: I0f63b53f2aae58871413b132742fc84138f069a3

Bugfix for screenshots (recent apps) due to incorrect rowBytes computation

bug: 12915192
cherry-pick from: I4d5fe2a2f75baf66099e0970fb646686a1992714

-----------------------------------------------------------------------

Fix bug in AndroidPixelRef where we did not store the correct imageInfo for a recycled bitmap.

cherry-pick from: I882483b78886e2f19fa4e43a86e69f5a82b3b7e5

-----------------------------------------------------------------------

Change-Id: Icaf597783da3ffb079ea18badb78fa31403bf8b8
2014-03-20 15:38:46 -04:00
Michael Wright
09cb894140 am 11e0ead8: am 69e58e44: Merge "Add idc config option for handling key repeats" into klp-modular-dev
* commit '11e0ead8118d97d0e76a98065a4811fdb01b2db2':
  Add idc config option for handling key repeats
2014-03-20 16:33:25 +00:00
Michael Wright
11e0ead811 am 69e58e44: Merge "Add idc config option for handling key repeats" into klp-modular-dev
* commit '69e58e446bc2a030ae423d650e60dbfe317331e6':
  Add idc config option for handling key repeats
2014-03-20 16:23:50 +00:00
Chris Craik
db2895e977 am 4eefde23: am 29f00c9f: am 7c9bd98a: am 89513ee5: Merge "Fix projection offset caching - DO NOT MERGE" into klp-dev
* commit '4eefde23de23a5e9145a634e843964f6f6eaa6bd':
  Fix projection offset caching - DO NOT MERGE
2014-03-20 16:05:02 +00:00
Chris Craik
4eefde23de am 29f00c9f: am 7c9bd98a: am 89513ee5: Merge "Fix projection offset caching - DO NOT MERGE" into klp-dev
* commit '29f00c9f35d8565bb3e6b8a2526cbb237db6446a':
  Fix projection offset caching - DO NOT MERGE
2014-03-20 15:47:34 +00:00
Chris Craik
d23d5b192a am 7c9bd98a: am 89513ee5: Merge "Fix projection offset caching - DO NOT MERGE" into klp-dev
* commit '7c9bd98a4bb0aa6954d5f612c197d03f309980f0':
  Fix projection offset caching - DO NOT MERGE
2014-03-20 15:42:24 +00:00
Michael Wright
69e58e446b Merge "Add idc config option for handling key repeats" into klp-modular-dev 2014-03-20 01:55:16 +00:00
Chris Craik
29f00c9f35 am 7c9bd98a: am 89513ee5: Merge "Fix projection offset caching - DO NOT MERGE" into klp-dev
* commit '7c9bd98a4bb0aa6954d5f612c197d03f309980f0':
  Fix projection offset caching - DO NOT MERGE
2014-03-20 01:14:44 +00:00
John Reck
c5dc251e22 Merge "Move RenderNode to own file" 2014-03-19 23:47:14 +00:00
John Reck
113e0824d6 Move RenderNode to own file
Change-Id: I9380d161fd3ddd7b569c262dd8e7aa0c96151b1e
2014-03-19 16:40:04 -07:00
Chris Craik
5d39a77992 Fix projection offset caching - DO NOT MERGE
bug:13214038

Because the caching of projection matrix didn't account for changes in
the offset flag, the flag could be ignored. Now we use both to verify
that the cached matrix can be used.

Change-Id: I193b94eaf0b98f046a6484f0866c3d25048653fd
(cherry picked from commit d04a6b15f74035fd2068f34225825b55e94521f4)
2014-03-19 20:09:04 +00:00
ztenghui
bd6e460b76 Merge "Get rid of useless code" 2014-03-19 19:59:47 +00:00
Mark Salyzyn
7e9e305994 am 9ca25502: am 48250e14: am 9a09a523: am 0b472ae1: Merge "androidfw: resolve 64-bit build issues"
* commit '9ca25502c05854288733ee5142e8bf6594821f83':
  androidfw: resolve 64-bit build issues
2014-03-19 19:58:00 +00:00
Mark Salyzyn
9ca25502c0 am 48250e14: am 9a09a523: am 0b472ae1: Merge "androidfw: resolve 64-bit build issues"
* commit '48250e141dc738578f6957f86ac841f3cb522057':
  androidfw: resolve 64-bit build issues
2014-03-19 19:52:02 +00:00
Mark Salyzyn
50fa0bd468 am 9a09a523: am 0b472ae1: Merge "androidfw: resolve 64-bit build issues"
* commit '9a09a5236529962afbaba9893e5eaf72bd6621b4':
  androidfw: resolve 64-bit build issues
2014-03-19 19:47:12 +00:00
Mark Salyzyn
48250e141d am 9a09a523: am 0b472ae1: Merge "androidfw: resolve 64-bit build issues"
* commit '9a09a5236529962afbaba9893e5eaf72bd6621b4':
  androidfw: resolve 64-bit build issues
2014-03-19 19:47:02 +00:00
Mark Salyzyn
9a09a52365 am 0b472ae1: Merge "androidfw: resolve 64-bit build issues"
* commit '0b472ae13d38dd166a1a35782e028ade85bf2975':
  androidfw: resolve 64-bit build issues
2014-03-19 12:42:15 -07:00