| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2012 Adobe Systems Incorporated. All rights reserved. | 2 * Copyright (C) 2012 Adobe Systems Incorporated. All rights reserved. |
| 3 * | 3 * |
| 4 * Redistribution and use in source and binary forms, with or without | 4 * Redistribution and use in source and binary forms, with or without |
| 5 * modification, are permitted provided that the following conditions | 5 * modification, are permitted provided that the following conditions |
| 6 * are met: | 6 * are met: |
| 7 * | 7 * |
| 8 * 1. Redistributions of source code must retain the above | 8 * 1. Redistributions of source code must retain the above |
| 9 * copyright notice, this list of conditions and the following | 9 * copyright notice, this list of conditions and the following |
| 10 * disclaimer. | 10 * disclaimer. |
| (...skipping 337 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 348 } else if (basic_shape_value.IsRayValue()) { | 348 } else if (basic_shape_value.IsRayValue()) { |
| 349 const CSSRayValue& ray_value = ToCSSRayValue(basic_shape_value); | 349 const CSSRayValue& ray_value = ToCSSRayValue(basic_shape_value); |
| 350 float angle = ray_value.Angle().ComputeDegrees(); | 350 float angle = ray_value.Angle().ComputeDegrees(); |
| 351 StyleRay::RaySize size = KeywordToRaySize(ray_value.Size().GetValueID()); | 351 StyleRay::RaySize size = KeywordToRaySize(ray_value.Size().GetValueID()); |
| 352 bool contain = !!ray_value.Contain(); | 352 bool contain = !!ray_value.Contain(); |
| 353 basic_shape = StyleRay::Create(angle, size, contain); | 353 basic_shape = StyleRay::Create(angle, size, contain); |
| 354 } else { | 354 } else { |
| 355 NOTREACHED(); | 355 NOTREACHED(); |
| 356 } | 356 } |
| 357 | 357 |
| 358 return basic_shape.Release(); | 358 return basic_shape; |
| 359 } | 359 } |
| 360 | 360 |
| 361 FloatPoint FloatPointForCenterCoordinate( | 361 FloatPoint FloatPointForCenterCoordinate( |
| 362 const BasicShapeCenterCoordinate& center_x, | 362 const BasicShapeCenterCoordinate& center_x, |
| 363 const BasicShapeCenterCoordinate& center_y, | 363 const BasicShapeCenterCoordinate& center_y, |
| 364 FloatSize box_size) { | 364 FloatSize box_size) { |
| 365 float x = FloatValueForLength(center_x.ComputedLength(), box_size.Width()); | 365 float x = FloatValueForLength(center_x.ComputedLength(), box_size.Width()); |
| 366 float y = FloatValueForLength(center_y.ComputedLength(), box_size.Height()); | 366 float y = FloatValueForLength(center_y.ComputedLength(), box_size.Height()); |
| 367 return FloatPoint(x, y); | 367 return FloatPoint(x, y); |
| 368 } | 368 } |
| 369 | 369 |
| 370 } // namespace blink | 370 } // namespace blink |
| OLD | NEW |