summaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2014-01-22Decouple parallaxSpeedMultiplier from setDecodeDimensions().Mark Wei
Expose decode vertical center through ExtendedOptions. Genericize BitmapDrawableImageView#getTypedDrawable(). Bug: 11691744 Change-Id: I62e05ab2136cf031eaf1752dba728156c97c87a6
2014-01-22Check if input stream is null first before blocking. This allows us to detectMark Wei
null cases without filling up the Executor queue. Bug: 11789572 Change-Id: Icef2f8da1239fdd8db9d74480a147081a15456bc
2014-01-21Check both ReusableBitmap and ReusableBitmap#bmp for null to avoid NPE.Mark Wei
Bug: 12617030 Change-Id: I5882be1f02413dd55f44bf09b68257e9690abb6c
2014-01-17Merge "Restore bounds when we recreate the placeholder and progress ↵Mark Wei
drawables." into klp-ub-dev
2014-01-17Restore bounds when we recreate the placeholder and progress drawables.Mark Wei
Change-Id: I9b63360a2bd34355c87528d143139764ec9aec38
2014-01-14Store null results in the cacheJames Kung
Change-Id: I034fa56a8c646a65781236fe832c0f54d9f86984
2014-01-07Export some useful custom classes that I wrote back into the bitmap library.Mark Wei
Added: - CircularBitmapDrawable: Use this if you want to display circular images with an optional border stroke. This class uses BitmapShaders, the preferred way of masking a bitmap, instead of using a non-rectangular clip region or overlaying views. - StyledCornersBitmapDrawable: Use this if you want the corners of your images to be stylized. You can choose from rounded or flap corners, with an optional border stroke and optional flap color. This class uses a non-rectangular clip region. In the future, this may change to use a BitmapShader. - ResourceRequestKey: Use this if you want a simple RequestKey implementation that loads images from a resource asset. Change-Id: If64440f3389f56f8a5b799a32a2660f3f9a19385
2014-01-06Allow non-changeable placeholder and progress drawable fields in ExtendedOptionsMark Wei
to be modified after ExtendedBitmapDrawable creation. Change-Id: Ia24ed7665df2a7ebe4359908c578a15e11e3801c
2013-12-11We expect the BitmapRegionDecoder to fail on a GIF. We need to reset theMark Wei
InputStream so the BitmapFactory decoder doesn't choke on a consumed InputStream. Bug: 12099499 Change-Id: Ie066e04f369cc51b783e2ce95ca4be5e5f8e8871
2013-12-08Allow placeholder drawable to be sized by the client. First try to use theMark Wei
bounds, then try to use the intrinsic bounds. When a key is null, set load state to FAILED instead of UNINITIALIZED. The difference is that FAILED shows the placeholder as a static image while UNINITIALIZED hides it. Fix bug in BitmapDrawableImageView where detaching from the window would set its drawable to null, throwing away state. Change-Id: I0b3f6c931d750ec4042e13bc1cbcf2d63e260168
2013-12-02Fix state changes bug that caused bitmaps in the cache to be faded in instead ofMark Wei
instantly shown. Change-Id: Ic2ba2d2ebe01badc881d1c43071a42bcf6f2b687
2013-11-22Background color of TileDrawable must be opaque.Mark Wei
Change-Id: I6ac7b4ba6f68181424064377464e1896c2129f13
2013-11-22Fix bug where the paint's color and alpha were overriding each other.Mark Wei
Change-Id: I47f41c3bc20243cef209c2c299642c024cf35652
2013-11-21Clarify ExtendedOptions validation documentation.Mark Wei
Change-Id: Ib89cb3268866888003567d76da45f0d6980dcc76
2013-11-20Allow clients to override draw(). This is useful for clients who wish toMark Wei
provide a border on top of all drawable layers, for instance. Change-Id: Ibcb4218bf213d9b0cc02256efdb6346043c0ee7e
2013-11-11Fix NPE in Robolectric tests.Mark Wei
Change-Id: Ib9422cd23940409c8301ea59f72e041972f5c58b
2013-11-08Have validate() ensure parllaxMultiplier is not 1Sam Blitzstein
If the parallax feature is turned on, validate() should check that parallaxSpeedMultiplier != 1. Change-Id: Id660c300cf86db62778f77acb2890a0ca9e8f6e0
2013-11-07Allow clients to customize the placeholder pulse animation.Mark Wei
Change-Id: I73564b39333c10876b4dbd4532da327b8cf45265
2013-11-06Merge "Fix bitmap drawing bug." into klp-ub-devMark Wei
2013-11-06Fix bitmap drawing bug.Mark Wei
The bitmap's bounds is not the true bounds, since the bitmaps are being reused. The true bounds are the decode bounds, or logical bounds of the ReusableBitmap. Bug: 11534712 Change-Id: I8fd5c35feacccbbfe6b625591cd56dec9ff3d716
2013-11-06Add javadoc explaining when to implement async FD vs sync IS methods.Mark Wei
Change-Id: I8a5e739c14d357b0b6b724cdbff45cd116458660
2013-11-05Change state from UNINITIALIZED to NOT_YET_LOADED earlier.Mark Wei
Relax restrictions on subclass. Change-Id: I456ed06e244de0ab794372b74094f9e94ed4b3f9
2013-11-04Add some documentation.Mark Wei
Change-Id: Ie32f29997946714d10318b111fabf4ed04e042e3
2013-11-04Allow subclasses to specify custom executors.Mark Wei
Change-Id: I5dba01d388189bd840cadb4543baf2544a4b2ca9
2013-11-04Consistent naming with onDraw().Mark Wei
Change-Id: I6fb90cc9f18abc97c17e5603b588039c717b63bb
2013-11-04Allow subclasses to customize drawing of bitmap (using shaders, etc).Mark Wei
Change-Id: I22294a19e6dd2247cc9679470b7b69089ba17228
2013-11-04Modify ExtendedBitmapDrawable to be more flexible for clients.Mark Wei
Introducing ExtendedOptions: Clients can now specify the features they want out of a ExtendedBitmapDrawable: 1) Ordered display (decode aggregator) 2) Parallax 3) State changes (placeholder and/or progress bar) Clients can also specify parameters to those features. These parameters can be modified and changes take effect immediately. Change-Id: I15e4f1dbc20473db6798888b07b4bd34c712db21
2013-10-31Make ExtendedBitmapDrawable extend BasicBitmapDrawable.Mark Wei
Modify sample app to use ExtendedBitmapDrawable with the following features: Parallax, Placholder and progress, Decode aggregator. Change-Id: Ia9e0fe6e6fdab018077a465ddf2a40109efbddf7
2013-10-31Manually inline methods that cause proguard to crash.Mark Wei
Bug: 11437985 Change-Id: Idf1b354bfcc97e6077e0855640a2abd6a9b36904
2013-10-30Merge "Make the bitmap sample app buildable in git." into klp-ub-devMark Wei
2013-10-30Make the bitmap sample app buildable in git.Mark Wei
The proguard config file causes proguard to fail on the analysis step when building with blaze in google3, proguard 4.9 It does not cause proguard to fail when building in git, proguard 4.4 Bug: 11437985 Change-Id: I67b2fd749c54ae8f5c5fda0dd7742a0f88918685
2013-10-29Relax BasicBitmapView to allow non-BasicBitmapDrawables to be assigned to it.Mark Wei
Rename BasicBitmapView to BitmapDrawableImageView. Allow asynchronous creating of file. Change-Id: I0407bf0bf36ae92ce45d2175121a15483f8f72f2
2013-10-22Add copyright.Mark Wei
Change-Id: I319143db9975244480d0bf4d8c1c3407ae719b14
2013-10-22Add BasicImageView to unbind on detach for clients with long-lived caches.Mark Wei
Change visibility of mBitmap back to private. Expose through getter. Bug: 11337575 Change-Id: I511976388cc3b6962434416d9e7a632e6d8a1b72
2013-10-22Merge "Expose sRect and mPaint to subclasses." into klp-ub-devMark Wei
2013-10-22Fix build breakage, use sdk 18.Sam Blitzstein
Change-Id: Icc2ba303023f9446b7aac1fb8fcccccdacda3e27
2013-10-21Expose sRect and mPaint to subclasses.Mark Wei
Change-Id: If9c994b3e5c19b66aaebe77f127c04ac9152994e
2013-10-22Merge "Change visibility of mBitmap to protected for BasicBitmapDrawable ↵Mark Wei
subclasses." into klp-ub-dev
2013-10-21Change visibility of mBitmap to protected for BasicBitmapDrawable subclasses.Mark Wei
Change-Id: I632138edd33f5fdc460d4525afea80ac0f2cf07f
2013-10-21Remove unused import.Mark Wei
Change-Id: I94aed7408c3765a2c2fc05573aa55bb98c72b17a
2013-10-21Fix bitmap sample.Mark Wei
Change-Id: I067a1b7f49ef0ad6ba746b7c35efde61de2cfc88
2013-10-21MisspellingMark Wei
Change-Id: I8ed71a18c95241997e9a91d0210bf8534f9891f8
2013-10-21Let BasicBitmapDrawable get subclassable.Mark Wei
Change-Id: I02024c858b0eb5442194ad6daf9204f02175caef
2013-10-21Modifications to bitmap library to make integrating into BigTop simpler.Mark Wei
RequestKey returns ParcelFileDescriptor instead of AssetFileDescriptor to make it easier to read files off of internal cache. Do not assume we want a top-1/3 crop. Provide vertical center in DecodeTask constructor. Move DecodeTask params into DecodeOptions to avoid param bloat. Add option to not limit bitmap density in BasicBitmapDrawable. Name AsyncTask threads in pool. Link DEBUG flags. Change-Id: I9416ac647c0c4935ee488b7db43cccd9de565c54
2013-10-17Changing sdk version from 16 to 18James Kung
Change-Id: I3bc55fcd7d4dc1d26d738e4ee8382fab1df004d5
2013-10-17Trace without reflection. Avoid crashing on ICS.Mark Wei
Change-Id: Ic75143a38d252278329a6f775c137ff1321eaf28
2013-10-16Add copyright notices, and clarify documentation.Sam Blitzstein
Remove ineffectual interface methods from RequestKey and replace with a comment in the class's documentation to the same meaning. Change-Id: I4d27407d18a798b27dfe138b38a5ee3a2718e127
2013-10-16Add sample app to bitmap library.Sam Blitzstein
Change-Id: Iec98361f576289447a274f51694d46974f1534ac
2013-10-16Change BitmapRequestKey to be more cleanly implementable.Sam Blitzstein
Change-Id: I831586688605e6c6c2f2f7a879c6be23175f71de
2013-10-15Initial commit from Gmail's Cache system.Sam Blitzstein
Change-Id: I14168ab3bc02b77399a1812f62bd77ac797232c5