diff options
author | reed <reed@google.com> | 2015-12-27 12:47:25 -0800 |
---|---|---|
committer | Commit bot <commit-bot@chromium.org> | 2015-12-27 12:47:25 -0800 |
commit | 9a878a00ef2c2eb72628c807be5969e2d8098317 (patch) | |
tree | dbd74fce2241f376ac2b3265e10bd9b04fdf499d /src/pipe | |
parent | 43a6f405e6aa0726fd18eb2b1575ac12ea093610 (diff) |
remove cruft from SkTypes.h, including SkBool
BUG=skia:
GOLD_TRYBOT_URL= https://gold.skia.org/search2?unt=true&query=source_type%3Dgm&master=false&issue=1548223002
TBR=
Review URL: https://codereview.chromium.org/1548223002
Diffstat (limited to 'src/pipe')
-rw-r--r-- | src/pipe/SkGPipeRead.cpp | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/src/pipe/SkGPipeRead.cpp b/src/pipe/SkGPipeRead.cpp index b48389abea..fa746bf2e9 100644 --- a/src/pipe/SkGPipeRead.cpp +++ b/src/pipe/SkGPipeRead.cpp @@ -84,6 +84,10 @@ public: ~SkRefCntTDArray() { this->unrefAll(); } }; +static inline uint32_t set_clear_mask(uint32_t bits, bool cond, uint32_t mask) { + return cond ? bits | mask : bits & ~mask; +} + class SkGPipeState : public SkBitmapHeapReader { public: SkGPipeState(); @@ -213,7 +217,7 @@ private: return; } bool crossProcess = SkToBool(fFlags & SkGPipeWriter::kCrossProcess_Flag); - fReader->setFlags(SkSetClearMask(fReader->getFlags(), crossProcess, + fReader->setFlags(set_clear_mask(fReader->getFlags(), crossProcess, SkReadBuffer::kCrossProcess_Flag)); if (crossProcess) { fReader->setFactoryArray(&fFactoryArray); |