2562 Commits

Author SHA1 Message Date
Alan Viverette
7a583e7bb3 Allow null layers in LayerDrawable
Bug: 20098214
Change-Id: I80285ddda7101ab7403048d38f9c40af6b692a1a
2015-04-13 11:03:55 -07:00
John Reck
a771b9861d Change how Java Bitmaps are accessed in a few places
Stop assuming that a Java Bitmap has a SkBitmap* that
has some externally managed lifecycle, and instead switch
a bunch of users to accessing the bitmap by providing
their own SkBitmap* on which to set the (ref counted!)
SkPixelRef* instead

Change-Id: I0fd9e193968b41e5597784140d56b4885906864a
2015-04-13 09:50:42 -07:00
Alan Viverette
d18c59b3e6 Merge "Don't change state when inflating LayerDrawable" 2015-04-10 17:50:21 +00:00
Alan Viverette
9eaa604116 Don't change state when inflating LayerDrawable
Bug: 20098214
Change-Id: I6968697053587454bba42c0652efd99b9c8a8e25
2015-04-09 17:28:24 -07:00
Alan Viverette
45f207d6d9 Only parse LayerDrawable child items when necessary
Bug: 20098214
Change-Id: Ie9da5f6e494ede47f9fdc94481a3f8ca41d3ef00
2015-04-09 13:14:32 -07:00
Chris Craik
b7acab634a Merge "Fix path clipping in VectorDrawable" 2015-04-06 18:05:00 +00:00
Chris Craik
e9c01a40a2 Fix path clipping in VectorDrawable
bug:19946683

Change-Id: I773957df7459eb72ea5d505afb0daac08239ecbf
2015-04-06 10:50:36 -07:00
ztenghui
df62ab4833 Merge "Add group scaling factor into stroke width." 2015-04-03 20:09:02 +00:00
Raph Levien
f673acb6c9 Merge "Add Paint.hasGlyph method" 2015-04-02 23:27:24 +00:00
Raph Levien
f7f969e67e Add Paint.hasGlyph method
This patch adds a method to determine whether a typeface has a glyph
to support a particular Unicode character or sequence.

The implementation is based on shaping the text and checking for the
presence of .notdef glyphs, and counting the number of glyphs in the
ligature case. In the case of variation selector control characters, it
currently just returns false because there is no variation selector
support yet (Mongolian Free Variation Selectors work because they're
shaped with GSUB instead).

Change-Id: I8ee4ae0d6e81a0ac57f961eb02dcc35aabd87042
2015-04-02 23:14:58 +00:00
ztenghui
9af77a4ce2 Add group scaling factor into stroke width.
Originally, stroke width is independent of group scaling.
But that is a bug and causing animation trouble.

b/19501782

Change-Id: I33d5e44f2f8b2a82fee1a5a326223a39aaffa86c
2015-04-02 16:09:03 -07:00
Chris Craik
ec3c97d27f Merge "Add compat path for restore underflow" 2015-04-02 22:38:49 +00:00
Chris Craik
3891f3ad59 Add compat path for restore underflow
bug:19829784

Change-Id: Ia761664208ab80c055ca11174db3ddc74457b92b
2015-04-02 15:30:32 -07:00
Yuichi Araki
a4dc29a721 am 428c2fa0: am c3fbf13d: am e2fc3adb: am 61ce6c9b: am 776cf41d: Fix a broken link in javadoc
* commit '428c2fa0f8b3c49e8bd48458c15363fcd98e8944':
  Fix a broken link in javadoc
2015-04-02 20:38:08 +00:00
Yuichi Araki
c3fbf13d52 am e2fc3adb: am 61ce6c9b: am 776cf41d: Fix a broken link in javadoc
* commit 'e2fc3adbb4040400496aebdab80c4cac1083da27':
  Fix a broken link in javadoc
2015-04-02 20:19:09 +00:00
Alan Viverette
0daa5713ee Merge "Fix issues with theming of preloaded ColorStateLists" 2015-04-02 18:02:04 +00:00
Yuichi Araki
776cf41d7c Fix a broken link in javadoc
Bug: 19856130

Change-Id: I0456e951f8bed36e3a62ddfd882f9c2d2bef9627
2015-04-02 04:03:07 +00:00
Seigo Nonaka
77840f4e8f Merge "Fix cursor position calculation." 2015-04-02 00:07:08 +00:00
Seigo Nonaka
b89a605b58 Fix cursor position calculation.
The cursor position calculation of not well known CharSequence implementation
has problem. getTextRunCursor() returns the relative path of passed string
buffer, so need to fix the origin by adding the copied buffer origin.

BUG: 17448027
Change-Id: I413c553bfccbccee4a390b6c83aa09ac7fd04126
2015-04-02 06:13:37 +09:00
Chet Haase
ffb73620a2 Fix Drawable.getOpacity() docs
Issue #17140095 Drawable#getOpacity() is documented as ignoring custom alpha, e.g. setAlpha(). It is lying.

Change-Id: Iaef094be750c58a43e13491e7bf9d9b7e56e23d2
2015-04-01 13:42:25 -07:00
Alan Viverette
e0f95f39c5 Fix issues with theming of preloaded ColorStateLists
Ensures changing configurations mask is propagated to the host drawable
so that it can be properly cleared from cache on configuration changes.
Also fixes constant state handling of the mask in the Inset and Rotate
drawables.

Hides new ColorStateList methods related to theming, since they should
only be used during preloading or internally by framework drawables.

Fixes bug where the cached versions of themeable ColorStateLists were
modified by calling applyTheme() on the host drawable.

Also cleans up some docs and naming in GradientDrawable.

Bug: 19966397
Change-Id: I8c8d3cabbaf94b488c2b8fe9fd423e07d824c19c
2015-04-01 13:10:18 -07:00
Yin-Chia Yeh
37ec99b19c Merge "Add RAW12 image format" 2015-03-31 18:27:23 +00:00
Zhijun He
2f17431194 ImageFormat: add PRIVATE format
Bug: 19865019
Change-Id: I1a9335fe1733a5b28d9cb20485b509fb216cb52b
2015-03-30 16:17:35 -07:00
Alan Viverette
acc6241da9 Merge "Only verify resolved theme attributes" 2015-03-27 18:03:08 +00:00
Alan Viverette
ee7c65d539 Only verify resolved theme attributes
Bug: 19962473
Change-Id: I62eb2faea7b09fd483194b41e815179cb2141fcb
2015-03-27 10:57:34 -07:00
ztenghui
304bbd117d Merge "Polish the documentation for VectorDrawable and AnimatedVectorDrawable" 2015-03-26 20:47:44 +00:00
ztenghui
0ea3aca4eb Polish the documentation for VectorDrawable and AnimatedVectorDrawable
Change-Id: If6bedf84cb01971c55b5a99ad921303dad638b24
2015-03-26 11:34:36 -07:00
ztenghui
34c623cbf3 Don't draw when bounds are negative
b/19922909

Change-Id: I68559ed683031f57538439e0a3e4979fe9f430a5
2015-03-25 15:01:58 -07:00
ztenghui
9c265091cf Merge "Add listener support in AVD" 2015-03-24 23:22:28 +00:00
ztenghui
1588f0ff54 Add listener support in AVD
Internally, switch to use AnimatorSet instead of an array of Animators

b/19825918

Change-Id: Ia67d2cc7dd89362e6b0019c916d3f2a0d0f3e39e
2015-03-24 15:49:13 -07:00
Andreas Gampe
84d9e0ef0b am 5e968ad1: am dde72862: am 7db6ebe0: Merge "Frameworks/base: Don\'t allocate another identity matrix"
* commit '5e968ad1d6c0387fb6b71b3693f5c0e95ccf469f':
  Frameworks/base: Don't allocate another identity matrix
2015-03-24 16:28:23 +00:00
Andreas Gampe
7db6ebe037 Merge "Frameworks/base: Don't allocate another identity matrix" 2015-03-24 16:02:55 +00:00
Yin-Chia Yeh
11d444f0b7 Add RAW12 image format
Change-Id: I1c528ecf62746aa96d6e132eaa874015d9d7c446
2015-03-20 17:40:01 -07:00
Alan Viverette
1b23240f96 Only propagate state changes if wrapped drawable is stateful
Always update layer bounds if the contained drawable changed in any
way. Also adds null annotations in LayerDrawable and throws a more
useful exception when the layers argument is null.

Change-Id: Iae0cba68257e48b6a45fe081c3d4b0509d2dedd5
2015-03-20 11:08:46 -07:00
Alan Viverette
fc8882f134 Clean up ripple exit, null out software animators on cancel/end
Bug: 19682421
Change-Id: I40ff56ed98a6c67cd01c74e455899825013a1f12
2015-03-18 17:26:54 -07:00
Chris Craik
43c410eaac Merge "Remove HardwareCanvas" 2015-03-18 21:36:56 +00:00
Andreas Gampe
7463438912 am 46277ba2: am 28e6aeca: Merge "Frameworks/base: Make IDENTITY_MATRIX final"
* commit '46277ba2c70e9fe0fc9772dcb84040aff1c322be':
  Frameworks/base: Make IDENTITY_MATRIX final
2015-03-17 22:02:36 +00:00
Andreas Gampe
28e6aeca3a Merge "Frameworks/base: Make IDENTITY_MATRIX final" 2015-03-17 21:33:09 +00:00
Andreas Gampe
399fa8a60a Frameworks/base: Make IDENTITY_MATRIX final
Bug: 19797138
Change-Id: I127f24b7060a0c4dab401ce8e3057d362c6d6b06
2015-03-17 21:31:42 +00:00
Tor Norbye
da81fa569e Merge "Add resource type annotations to some APIs" 2015-03-16 21:20:31 +00:00
Andreas Gampe
08067d9829 am 8e176d39: am 007e207b: Merge "Frameworks/base: Fix null-pointer check"
* commit '8e176d396d393af90ffe288d849e95ff40aa2b23':
  Frameworks/base: Fix null-pointer check
2015-03-16 17:20:12 +00:00
Andreas Gampe
d538fa0fb2 Frameworks/base: Don't allocate another identity matrix
There is already an identity matrix in Matrix. Don't allocate another
one for VectorDrawable.

Change-Id: I51735f262d6680e043b0009707ec42acb2d0d1ad
2015-03-15 19:03:29 -07:00
Andreas Gampe
f2b1cff4e2 Frameworks/base: Fix null-pointer check
Change-Id: I715a21c313e909ae654e0c1aa67bdf7bcd89de76
2015-03-15 15:07:19 -07:00
Raph Levien
210a189e22 Add HyphenEdit support to Paint
This adds HyphenEdit on the C++ and also to Java via JNI. HyphenEdit is
a Minikin feature for adding hyphens to text without having to edit the
string on the client side.

Change-Id: Icfb228407c1d11a716d055f813da7507acb38fbf
2015-03-14 06:00:23 +00:00
Tor Norbye
417ee5ba89 Add resource type annotations to some APIs
Change-Id: I37c8afdaea455aa92bc8270bb2dfd60616c5f9bc
2015-03-13 11:20:45 -07:00
Chris Craik
f6829a0a61 Remove HardwareCanvas
Change-Id: I239646a7f00f09d3f76fe6b6162eed86bc0d6e77
2015-03-10 14:56:11 -07:00
Alan Viverette
6a67db4138 Implement bounded ripple animation
Bug: 19431322
Change-Id: I5dc1a28d8675cc6fb036b815d6227113c3f1aa4b
2015-03-09 18:54:25 -07:00
Alan Viverette
53776a2b3c Merge "Refactor ripple components, simplify background animation" 2015-03-10 01:51:59 +00:00
Alan Viverette
f872ee0057 Refactor ripple components, simplify background animation
Moves animation lifecycle and software/hardware hand-off into a unified
RippleComponent class, which makes it easier to maintain the components.
Adds better javadocs and comments to explain what's going on.

Bug: 19431322
Change-Id: Ifb9b9a7dcc24238719ef12293493ca3df107679f
2015-03-09 18:25:21 -07:00
Eino-Ville Talvala
805f3c9428 Add DEPTH image formats, support in ImageReader
- Add an explicit mapping between public ImageFormat/
  PixelFormat enums and internal HAL format/dataspace.
- Add DEPTH16 and DEPTH_POINT_CLOUD formats
- Wire up mapping layer to ImageReader to support depth
  formats

Change-Id: I8197eccef900cc91baddcfcb934ccd4d8c972eff
2015-03-09 16:42:25 -07:00