| Index: sky/engine/core/painting/PaintingStyle.cpp
|
| diff --git a/sky/engine/core/painting/TransferMode.cpp b/sky/engine/core/painting/PaintingStyle.cpp
|
| similarity index 50%
|
| copy from sky/engine/core/painting/TransferMode.cpp
|
| copy to sky/engine/core/painting/PaintingStyle.cpp
|
| index afd168e3d1425408ee6fa6d4d4af299c0cfec1fd..31f39e0287c60198cf32fa6653fd1b0a9bd129d0 100644
|
| --- a/sky/engine/core/painting/TransferMode.cpp
|
| +++ b/sky/engine/core/painting/PaintingStyle.cpp
|
| @@ -3,7 +3,7 @@
|
| // found in the LICENSE file.
|
|
|
| #include "sky/engine/config.h"
|
| -#include "sky/engine/core/painting/TransferMode.h"
|
| +#include "sky/engine/core/painting/PaintingStyle.h"
|
|
|
| #include "sky/engine/core/script/dom_dart_state.h"
|
| #include "sky/engine/tonic/dart_builtin.h"
|
| @@ -13,28 +13,28 @@
|
| namespace blink {
|
|
|
| // If this fails, it's because SkXfermode has changed. We need to change
|
| -// TransferMode.dart to ensure the TransferMode enum is in sync with the C++
|
| +// PaintingStyle.dart to ensure the PaintingStyle enum is in sync with the C++
|
| // values.
|
| -COMPILE_ASSERT(SkXfermode::kLastMode == 28, Need_to_update_TransferMode_dart);
|
| +COMPILE_ASSERT(SkPaint::kStyleCount == 3, Need_to_update_PaintingStyle_dart);
|
|
|
| -// Convert dart_mode => SkXfermode::Mode.
|
| -SkXfermode::Mode DartConverter<TransferMode>::FromArgumentsWithNullCheck(
|
| +// Convert dart_style => SkPaint::Style.
|
| +SkPaint::Style DartConverter<PaintingStyle>::FromArgumentsWithNullCheck(
|
| Dart_NativeArguments args,
|
| int index,
|
| Dart_Handle& exception) {
|
| - SkXfermode::Mode result;
|
| + SkPaint::Style result;
|
|
|
| - Dart_Handle dart_mode = Dart_GetNativeArgument(args, index);
|
| - DCHECK(!LogIfError(dart_mode));
|
| + Dart_Handle dart_style = Dart_GetNativeArgument(args, index);
|
| + DCHECK(!LogIfError(dart_style));
|
|
|
| Dart_Handle value =
|
| - Dart_GetField(dart_mode, DOMDartState::Current()->index_handle());
|
| + Dart_GetField(dart_style, DOMDartState::Current()->index_handle());
|
|
|
| - uint64_t mode = 0;
|
| - Dart_Handle rv = Dart_IntegerToUint64(value, &mode);
|
| + uint64_t style = 0;
|
| + Dart_Handle rv = Dart_IntegerToUint64(value, &style);
|
| DCHECK(!LogIfError(rv));
|
|
|
| - result = static_cast<SkXfermode::Mode>(mode);
|
| + result = static_cast<SkPaint::Style>(style);
|
| return result;
|
| }
|
|
|
|
|