| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2006, 2008 Apple Inc. All rights reserved. | 2 * Copyright (C) 2006, 2008 Apple Inc. All rights reserved. |
| 3 * Copyright (C) 2008, 2010 Nokia Corporation and/or its subsidiary(-ies) | 3 * Copyright (C) 2008, 2010 Nokia Corporation and/or its subsidiary(-ies) |
| 4 * Copyright (C) 2007 Alp Toker <alp@atoker.com> | 4 * Copyright (C) 2007 Alp Toker <alp@atoker.com> |
| 5 * Copyright (C) 2008 Eric Seidel <eric@webkit.org> | 5 * Copyright (C) 2008 Eric Seidel <eric@webkit.org> |
| 6 * | 6 * |
| 7 * Redistribution and use in source and binary forms, with or without | 7 * Redistribution and use in source and binary forms, with or without |
| 8 * modification, are permitted provided that the following conditions | 8 * modification, are permitted provided that the following conditions |
| 9 * are met: | 9 * are met: |
| 10 * 1. Redistributions of source code must retain the above copyright | 10 * 1. Redistributions of source code must retain the above copyright |
| (...skipping 110 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 121 flags, AffineTransformToSkMatrix(GetCanvasPattern()->GetTransform())); | 121 flags, AffineTransformToSkMatrix(GetCanvasPattern()->GetTransform())); |
| 122 break; | 122 break; |
| 123 default: | 123 default: |
| 124 NOTREACHED(); | 124 NOTREACHED(); |
| 125 } | 125 } |
| 126 } | 126 } |
| 127 | 127 |
| 128 RGBA32 CanvasStyle::PaintColor() const { | 128 RGBA32 CanvasStyle::PaintColor() const { |
| 129 if (type_ == kColorRGBA) | 129 if (type_ == kColorRGBA) |
| 130 return rgba_; | 130 return rgba_; |
| 131 ASSERT(type_ == kGradient || type_ == kImagePattern); | 131 DCHECK(type_ == kGradient || type_ == kImagePattern); |
| 132 return Color::kBlack; | 132 return Color::kBlack; |
| 133 } | 133 } |
| 134 | 134 |
| 135 DEFINE_TRACE(CanvasStyle) { | 135 DEFINE_TRACE(CanvasStyle) { |
| 136 visitor->Trace(gradient_); | 136 visitor->Trace(gradient_); |
| 137 visitor->Trace(pattern_); | 137 visitor->Trace(pattern_); |
| 138 } | 138 } |
| 139 | 139 |
| 140 } // namespace blink | 140 } // namespace blink |
| OLD | NEW |