| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2013 Google Inc. All rights reserved. | 2 * Copyright (C) 2013 Google Inc. 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 are | 5 * modification, are permitted provided that the following conditions are |
| 6 * met: | 6 * met: |
| 7 * | 7 * |
| 8 * * Redistributions of source code must retain the above copyright | 8 * * Redistributions of source code must retain the above copyright |
| 9 * notice, this list of conditions and the following disclaimer. | 9 * notice, this list of conditions and the following disclaimer. |
| 10 * * Redistributions in binary form must reproduce the above | 10 * * Redistributions in binary form must reproduce the above |
| (...skipping 27 matching lines...) Expand all Loading... |
| 38 : m_parent(0) | 38 : m_parent(0) |
| 39 , m_startTime(0) | 39 , m_startTime(0) |
| 40 , m_specified(timing) | 40 , m_specified(timing) |
| 41 , m_calculated() | 41 , m_calculated() |
| 42 { | 42 { |
| 43 timing.assertValid(); | 43 timing.assertValid(); |
| 44 } | 44 } |
| 45 | 45 |
| 46 void TimedItem::updateInheritedTime(double inheritedTime) const | 46 void TimedItem::updateInheritedTime(double inheritedTime) const |
| 47 { | 47 { |
| 48 ASSERT(player()); |
| 48 const double localTime = inheritedTime - m_startTime; | 49 const double localTime = inheritedTime - m_startTime; |
| 49 const double iterationDuration = m_specified.hasIterationDuration | 50 const double iterationDuration = m_specified.hasIterationDuration |
| 50 ? m_specified.iterationDuration | 51 ? m_specified.iterationDuration |
| 51 : intrinsicIterationDuration(); | 52 : intrinsicIterationDuration(); |
| 52 | 53 |
| 53 const double repeatedDuration = iterationDuration * m_specified.iterationCou
nt; | 54 const double repeatedDuration = iterationDuration * m_specified.iterationCou
nt; |
| 54 const double activeDuration = m_specified.playbackRate | 55 const double activeDuration = m_specified.playbackRate |
| 55 ? repeatedDuration / abs(m_specified.playbackRate) | 56 ? repeatedDuration / abs(m_specified.playbackRate) |
| 56 : std::numeric_limits<double>::infinity(); | 57 : std::numeric_limits<double>::infinity(); |
| 57 | 58 |
| (...skipping 42 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 100 , currentIteration(nullValue()) | 101 , currentIteration(nullValue()) |
| 101 , timeFraction(nullValue()) | 102 , timeFraction(nullValue()) |
| 102 , isScheduled(false) | 103 , isScheduled(false) |
| 103 , isActive(false) | 104 , isActive(false) |
| 104 , isCurrent(false) | 105 , isCurrent(false) |
| 105 , isInEffect(false) | 106 , isInEffect(false) |
| 106 { | 107 { |
| 107 } | 108 } |
| 108 | 109 |
| 109 } // namespace WebCore | 110 } // namespace WebCore |
| OLD | NEW |