add guard to switch to SkPathTypes
Change-Id: I44d8b5ae8a5172d11a6d4cd9d994373dd3816d6f
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/241278
Reviewed-by: Kevin Lubick <kjlubick@google.com>
Reviewed-by: Florin Malita <fmalita@chromium.org>
Commit-Queue: Mike Reed <reed@google.com>
diff --git a/src/pathops/SkPathOpsAsWinding.cpp b/src/pathops/SkPathOpsAsWinding.cpp
index 80e52be..c415087 100644
--- a/src/pathops/SkPathOpsAsWinding.cpp
+++ b/src/pathops/SkPathOpsAsWinding.cpp
@@ -367,7 +367,7 @@
const SkPath& fPath;
};
-static bool set_result_path(SkPath* result, const SkPath& path, SkPath::FillType fillType) {
+static bool set_result_path(SkPath* result, const SkPath& path, SkPathFillType fillType) {
*result = path;
result->setFillType(fillType);
return true;
@@ -377,13 +377,13 @@
if (!path.isFinite()) {
return false;
}
- SkPath::FillType fillType = path.getFillType();
- if (fillType == SkPath::kWinding_FillType
- || fillType == SkPath::kInverseWinding_FillType ) {
+ SkPathFillType fillType = (SkPathFillType)path.getFillType();
+ if (fillType == SkPathFillType::kWinding
+ || fillType == SkPathFillType::kInverseWinding ) {
return set_result_path(result, path, fillType);
}
- fillType = path.isInverseFillType() ? SkPath::kInverseWinding_FillType :
- SkPath::kWinding_FillType;
+ fillType = path.isInverseFillType() ? SkPathFillType::kInverseWinding :
+ SkPathFillType::kWinding;
if (path.isEmpty() || path.isConvex()) {
return set_result_path(result, path, fillType);
}