1958 Commits

Author SHA1 Message Date
Chris Craik
757f0f36b9 Merge "Implement outline support for nine patches" into lmp-dev 2014-07-14 22:55:21 +00:00
Chris Craik
47cd8e921d Implement outline support for nine patches
b/15856895

Nine patches now have outline round rect metadata stored as optional
png tags. aapt generates these automatically by inspecting the bitmap
pixels to estimate outline bounds and round rect radius, based on
opacity.

Change-Id: I226e328a97873010d9e1adb797ac48f93a31183c
2014-07-14 15:01:27 -07:00
ztenghui
dc4335408b Merge "Enable the bitmap cache for the VectorDrawable" into lmp-dev 2014-07-14 18:37:52 +00:00
ztenghui
482eb53c8a Enable the bitmap cache for the VectorDrawable
b/16299765

Change-Id: Ia2c0fd366abc097d1ce485936de74e4e898cc07a
2014-07-14 15:49:04 -07:00
Eino-Ville Talvala
b942b05093 Deprecate android.hardware.Camera
__
             ||
             ||
             ||
             ||---____-----+
             ||    \_/     |
             ||   /. .\    |
             ||  ||---||   |
             ||   |___|    |
             ||    | |     |
             ||---____-----+
             ||
             ||
             ||
_____________||_________________

Replaced by android.hardware.camera2

- Also deprecate MediaRecorder#setCamera
- Also deprecate all Camera inner classes
- Update reference documentation in various classes to point to camera2
- Add note to camera API guide that it uses the old API
  (until a new guide is available)
- Remove old hidden raw sensor format; superceded by RAW_SENSOR.

Change-Id: I3d839765fc9b9aae906751ee32d6956ef40451ce
2014-07-13 21:45:57 -07:00
Alan Viverette
935b1fa24d Remove old RippleDrawable constructor, fix new constructor
BUG: 16221737
Change-Id: I3807d8d7ccccf66568b9d5421cb9456fe818e2bf
2014-07-11 12:34:06 -07:00
Leon Scroggins III
d66a8719b0 Merge "Simplify Shader.setLocalMatrix." 2014-07-10 21:35:02 +00:00
Leon Scroggins III
ab87983a11 Simplify Shader.setLocalMatrix.
Previously, calling setLocalMatrix updated any Paint that had the
Shader attached. This depended on deprecated behavior in Skia. Use
new Skia APIs, and do not modify any Paints that use the Shader.

In addition, update callers to call setShader (again) after modifying
the Shader.

Sample app at ag/499573 for testing.

Depends on I673801444f0a8fd4f192b5b7effdde1aa83e702b in external/skia.

BUG:14315916
Change-Id: I3c3316377874e89fccc85afb864bc038b0ef3890
2014-07-10 18:01:22 -04:00
Alan Viverette
4c33b9f7d4 Merge "Remove material progress drawable" 2014-07-10 20:54:59 +00:00
Alan Viverette
d7f4a3cdd7 Remove material progress drawable
BUG: 16138805
Change-Id: If8a8981e6ce741d563e870e3c09cbb5f39d30ac9
2014-07-10 15:48:37 -07:00
ztenghui
8d0d24f7a2 Fix the render order to follow the XML file order.
So we put path and group into a big list, then use reflectiont to handle them
differently.

bug:16162141

Change-Id: I4c84dc952d5d9b49412301dcd6459395e21d3b31
2014-07-10 22:04:20 +00:00
Svet Ganov
525a66b2bb Adding print preview.
This change adds the pring preview part of the new print UX. The
UI has two parts, the top section is the print options and the
bottom section print preview with a list of pages. The user can
interact only with one of them. When print options are expanded
they cover the preview content and a scrim is laid out on top of
the preview. Tapping the scrim collapses the print options. When
the user types in page ranges and closes the options to look at
the preview, the latter is updated to show only these pages. In
the list of pages the user can further prune pages by deselecting
them.

Change-Id: I0b23d2c598afe2a34400ccfa43e4e935af83c72f
2014-07-09 18:43:38 +00:00
ztenghui
55f765441c Add constant state support back to VectorDrawable
At the same time, AVD is using a mutated version of VD.
And AVD won't support constant state.
Move the targetsMap down into constant state.

bug:16017895

Change-Id: I12fbc52a8719362adba9df1e0f97288decbd33b2
2014-07-09 16:05:36 +00:00
Alan Viverette
9e6f9924c4 Fix layer drawable inflation
Change-Id: I2f16e3ddea919c33dc7b62f457a994e6d8a66e5b
2014-07-07 17:12:42 -07:00
Alan Viverette
13d965485e Fix build
Change-Id: I20f3ae19bd6d7cdc6dd6b9e947bdfea38893a167
2014-07-07 23:30:56 +00:00
Alan Viverette
8e5e11b99f Handle configuration changes in drawable attributes
Adds themeable attribute support to InsetDrawable, adds support
for attribute configuration changes to all themable drawables.

BUG: 16045735
Change-Id: I3dc62d28801760ac69d303be81b6c78bb9bb5aca
2014-07-07 22:54:22 +00:00
Alan Viverette
7c0517272b Fix getOutline() in ripple and layer drawables
BUG: 16134862
Change-Id: Ibcef20fc154ecc342344770f96fbd3d77d6fad26
2014-07-07 15:29:12 -07:00
Alan Viverette
2a0d4a1fff Merge "Update AnimatedStateListDrawable to work with Animatable drawables" 2014-07-07 17:47:39 +00:00
Alan Viverette
f456b1f078 Update AnimatedStateListDrawable to work with Animatable drawables
BUG: 16016730
Change-Id: I6d02a1235c0aecd7e62f12226f3689372d043ddd
2014-07-03 19:03:21 -07:00
Zhijun He
d1988a98ed Add RAW10 image format
- Add RAW10 format in ImageFormat
- Add ImageReader support for this format

Bug: 15989722
Change-Id: Ic38ae596d5a472e990389d1fa221a82bea97b715
2014-07-07 08:01:06 -07:00
Nick Kralevich
617dca9242 am 50c3c114: am 664ec0a6: am 77491ac0: Merge "Correct typo in doc comment"
* commit '50c3c114603b493d7814c83f96c8057e040e6c28':
  Correct typo in doc comment
2014-07-05 17:12:08 +00:00
Nick Kralevich
826504249d am 7ea31c67: am c43f3eb6: am 8b333467: Merge "fix trivial typo: s/meansure/measure"
* commit '7ea31c67f707be3fa208f93fa458068d57545e77':
  fix trivial typo: s/meansure/measure
2014-07-05 17:11:55 +00:00
Nick Kralevich
50c3c11460 am 664ec0a6: am 77491ac0: Merge "Correct typo in doc comment"
* commit '664ec0a6e6cedf47adc54f2e0cd8f1435d699b72':
  Correct typo in doc comment
2014-07-05 17:06:11 +00:00
Nick Kralevich
7ea31c67f7 am c43f3eb6: am 8b333467: Merge "fix trivial typo: s/meansure/measure"
* commit 'c43f3eb67bbf60af61b3cd18bc5b6a684c8744c6':
  fix trivial typo: s/meansure/measure
2014-07-05 17:05:58 +00:00
Nick Kralevich
8b333467fe Merge "fix trivial typo: s/meansure/measure" 2014-07-03 01:32:01 +00:00
Jason Sams
24bea6a3ef Resolve conflicts with AOSP.
Change-Id: I2f1afdb83dcfc9078df5d3c2f13abacb6504d73d
2014-07-02 14:32:24 -07:00
Nick Kralevich
77491ac00c Merge "Correct typo in doc comment" 2014-07-02 20:52:43 +00:00
Alan Viverette
c054966b71 Make optical insets actually work
Change-Id: I9fabf4cb939cc7a868f95580e7229745acde0418
2014-07-04 01:10:38 +00:00
Leon Scroggins III
57ee620ced Read premultiplied status from the SkBitmap.
Replace the Java variable with mRequestPremultiplied, to better
reflect what it represents. In both native and Java, the SkBitmap
is used as the decision maker of whether a Bitmap is premultiplied.
When changing other settings, mRequestedPremultiplied is used to
determine whether it should be premultiplied (if the new config/
hasAlpha-ness etc supports it).

ChooseFromColorProc now reads both the colortype (instead of the
deprecated Config) and alphatype on the SkBitmap. Same with
ChooseToColorProc. In the process, this caught a bug, where the
wrong procs were being used for Index8.

Replace instances of SkBitmap::Config with SkColorType where I
was already changing code.

Use the new versions of setConfig/allocPixels that take an SkImageInfo
as a parameter.

Document isPremultiplied's return value for ALPHA_8.

BUG:13618134
Change-Id: I91fc1f1e46e9294364b1af0ab4bdb37c68d7058e
2014-07-01 14:05:37 -04:00
Chris Craik
9a347f1992 Initial replacement of setOutline() with ViewOutlineProvider API
bug:15283203

A View's outline is now managed by its outline provider. This means
the outline is automatically requeried when needed (e.g. drawable
updates or resize), with customizable querying behavior.

Also adds 'isFilled' property to outline, to be used for hinting
shadow overdraw avoidance.

Change-Id: Ie137548fa850f1ff7863ab2f660d05145c2ad11e
2014-07-01 00:16:25 +00:00
ztenghui
9e31cfa92c Merge "Use AnimatedVectorDrawable for progress bar." 2014-06-30 14:43:31 +00:00
ztenghui
9cb5b4c2d9 Use AnimatedVectorDrawable for progress bar.
Change-Id: I419197ef38a611757f27ca3192350ad4bd403875
2014-06-30 12:43:52 -07:00
Alan Viverette
6ae2d7cefa Don't call deprecated RippleDrawable constructor
BUG: 15972806
Change-Id: If0973eed2da4708312a1320be4dd0b314157bc9a
2014-06-30 11:34:21 -07:00
Chris Craik
3e1585e05d Add outline support to InsetDrawable
bug:15933107
Change-Id: I3341417dc197a751442d2b4c2645a1520db41095
2014-06-30 17:53:05 +00:00
Alan Viverette
9550acf1e9 Merge "Require color in RippleDrawable constructor, fix documentation" 2014-06-27 16:52:20 +00:00
Alan Viverette
7275abde37 Require color in RippleDrawable constructor, fix documentation
Marks old constructor for removal and emits LOG_E when used.

BUG: 15808263
Change-Id: Iae4f3237261541cb04f42343351b3fc0ac4929ac
2014-06-27 14:34:54 -07:00
Alan Viverette
100a2d1fc6 Clean up AnimationDrawable.setVisible() state management
BUG: 15823683
Change-Id: Ied0d476956c246bdfda66219aaa896f2ef58f0bd
2014-06-27 13:15:14 -07:00
Dan Stoza
493f2e1190 SurfaceTexture: Allow creation in detached mode
Adds a constructor that doesn't require a GLES texture name and sets
up the SurfaceTexture in detached mode.

Bug: 15616428
Change-Id: I375495f481bfbe43b3830ab7d124cef8f1be0ac6
2014-06-26 13:36:19 -07:00
Raph Levien
3660789f06 Switch all text layout to Minikin
This patch switches all text layout operations to use Minikin, removes
the USE_MINIKIN #ifdef, and deletes some of the code that was only used
in the old TextLayout path (although some more refactoring remains).

Change-Id: I51b5c4e2bb46cfd9d204c12b9f16f135c769f5b5
2014-06-26 08:23:48 -07:00
Raph Levien
d194262f53 Delete Paint.getTextGlyphs()
The Paint.getTextGlyphs() method was used for testing the old Arabic
shaper and is entirely obsolete. Note that this is the very last
dependency (other than some enums in the header) for the old TextLayout
code path.

Change-Id: I7b596f0c0942ed50987fc8e0478cd93e667f1f9e
2014-06-26 15:15:28 +00:00
Chris Craik
58945975b2 Outline support in DrawableContainer and LayerDrawable
bug:14445484
Change-Id: I26a45b0115b976d0dbcc351a208dc0956bc52e96
2014-06-24 15:56:05 -07:00
Alan Viverette
22594f0972 Add tileModeX/Y attrs to BitmapDrawable, tint to ShapeDrawable
Change-Id: I1c9efe39bfd5286230cee8354822db81f05186e4
2014-06-23 12:47:43 -07:00
ztenghui
f2d0020d93 Merge "Make AnimatedVectorDrawable public." 2014-06-20 20:04:02 +00:00
ztenghui
7e7ea9da67 Make AnimatedVectorDrawable public.
Clean up some useless VectorDrawable functions.
Add comments, too.

Change-Id: I8cc2165d14d09fd71f5830c4f61f9e8ac1d7c8da
2014-06-23 09:36:52 -07:00
ztenghui
eb034fbca4 AVD now support path morphing.
Basically extended the ValueAnimator to support a new type: pathType.
Add the PathDataEvaluator internally to interpolate path data.
Update test to show the path morphing.

Change-Id: I89db0199cbc12e3041790a6115f3f50b80213cdb
2014-06-20 15:16:47 -07:00
Chet Haase
3aff2a0813 Avoid resetting gradient state when not actually rebuilding it
Previous logic in GradientDrawable around rebuilding the gradient path
was incorrect, but it happened to work because of when it was called
(after ensureValidRect() in the draw() method). Further reliance on this
logic outside of the drawing cycle (in the new getOutline() method) caused
the side-effect to surface as we now clear the dirty flag without actually
rebuilding the gradient.

Fix avoids resetting the flag outside of ensureValidRect() where it belongs.

Issue #15508378 Quantum ui having issues with viewing comments on facebook app

Change-Id: Ia944d3de7e3c0920fed040188e8c1cc1bcce498d
2014-06-21 08:31:03 -07:00
ztenghui
02aefd779e Merge "AVD now support path morphing." 2014-06-20 02:09:17 +00:00
Alan Viverette
9cd14fc710 Add support for tint attribute in VectorDrawable
Fixes NPE from previous change. Also fixes docs reference in TypedArray.

BUG: 15375203
Change-Id: Icf3b5759780276b0875a4fb70b29522ab7c8cb90
2014-06-20 14:45:11 -07:00
Dianne Hackborn
5ff885cd3b Revert "Add support for tint attribute in VectorDrawable"
This reverts commit ab41ea17e6b0407fa76bc9f9183190a9bbc7f560.

Was causing system UI to crash.
2014-06-19 23:02:37 -07:00
Alan Viverette
e93c90126b Merge "Add support for tint attribute in VectorDrawable" 2014-06-20 00:06:01 +00:00