aboutsummaryrefslogtreecommitdiffhomepage
path: root/include/core/SkSize.h
diff options
context:
space:
mode:
authorGravatar Mike Reed <reed@google.com>2017-02-17 17:06:11 -0500
committerGravatar Skia Commit-Bot <skia-commit-bot@chromium.org>2017-02-17 22:49:59 +0000
commitf67c45994dedc96eb979e331ab156649847071a4 (patch)
tree2fe1634895566c3340e62aeaec74170ca36cd7c8 /include/core/SkSize.h
parente005edd3a5deb602beec59f59cdc8b14d3764d58 (diff)
add ViaSVG to dm
BUG=skia: Change-Id: I52892a0dd466bee6e3abcaa89a373b93493d201f Reviewed-on: https://skia-review.googlesource.com/8682 Commit-Queue: Mike Reed <reed@google.com> Reviewed-by: Mike Klein <mtklein@chromium.org> Reviewed-by: Florin Malita <fmalita@chromium.org>
Diffstat (limited to 'include/core/SkSize.h')
-rw-r--r--include/core/SkSize.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/include/core/SkSize.h b/include/core/SkSize.h
index 7bc8c7165d..2efcfb59dc 100644
--- a/include/core/SkSize.h
+++ b/include/core/SkSize.h
@@ -82,6 +82,9 @@ struct SkSize : public SkTSize<SkScalar> {
return s;
}
+ static SkSize Make(const SkISize& src) {
+ return Make(SkIntToScalar(src.width()), SkIntToScalar(src.height()));
+ }
SkSize& operator=(const SkISize& src) {
this->set(SkIntToScalar(src.fWidth), SkIntToScalar(src.fHeight));