aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJean-Baptiste Queru <jbq@google.com>2011-06-13 13:26:18 -0700
committerJean-Baptiste Queru <jbq@google.com>2011-06-13 13:26:18 -0700
commit6d8b2f6f345bd0722bd0a6c16448fbf32e5d1226 (patch)
tree58f279d58679e524a437e7b581ef42e5a9bd5ad8
parent2c0116a6929eab6e3a31d03a7389a28673927bb3 (diff)
downloadskia-6d8b2f6f345bd0722bd0a6c16448fbf32e5d1226.tar.gz
Fix build - restore older behaviors
Change-Id: Ie9f88806b1083f0b4ef99731bd4f1e42fff467fe
-rw-r--r--include/effects/SkLayerDrawLooper.h4
-rw-r--r--src/effects/SkLayerDrawLooper.cpp4
2 files changed, 4 insertions, 4 deletions
diff --git a/include/effects/SkLayerDrawLooper.h b/include/effects/SkLayerDrawLooper.h
index 8627ae4b8e..acc4f9b8ff 100644
--- a/include/effects/SkLayerDrawLooper.h
+++ b/include/effects/SkLayerDrawLooper.h
@@ -74,12 +74,12 @@ public:
/**
* This layer will draw with the original paint, ad the specified offset
*/
- void addLayer(SkScalar dx, SkScalar dy);
+ SkPaint* addLayer(SkScalar dx, SkScalar dy);
/**
* This layer will with the original paint and no offset.
*/
- void addLayer() { this->addLayer(0, 0); }
+ SkPaint* addLayer() { return this->addLayer(0, 0); }
// overrides from SkDrawLooper
virtual void init(SkCanvas*);
diff --git a/src/effects/SkLayerDrawLooper.cpp b/src/effects/SkLayerDrawLooper.cpp
index 5d0fdcfcc4..34c32384fc 100644
--- a/src/effects/SkLayerDrawLooper.cpp
+++ b/src/effects/SkLayerDrawLooper.cpp
@@ -37,11 +37,11 @@ SkPaint* SkLayerDrawLooper::addLayer(const LayerInfo& info) {
return &rec->fPaint;
}
-void SkLayerDrawLooper::addLayer(SkScalar dx, SkScalar dy) {
+SkPaint* SkLayerDrawLooper::addLayer(SkScalar dx, SkScalar dy) {
LayerInfo info;
info.fOffset.set(dx, dy);
- (void)this->addLayer(info);
+ return this->addLayer(info);
}
void SkLayerDrawLooper::init(SkCanvas* canvas) {