diff options
author | bsalomon@google.com <bsalomon@google.com@2bbb7eff-a529-9590-31e7-b0007b416f81> | 2012-01-06 19:22:11 +0000 |
---|---|---|
committer | bsalomon@google.com <bsalomon@google.com@2bbb7eff-a529-9590-31e7-b0007b416f81> | 2012-01-06 19:22:11 +0000 |
commit | cadbcb8e536f89babb4e165bfdca18384e97d582 (patch) | |
tree | 9621167209d605e969b13b1ab39963a62591a8ac /src/animator/SkAnimateActive.cpp | |
parent | baa9ea10f9b704f42efc804e7401e0aa519b3e29 (diff) |
Towards enabling -Werror in skia on Linux
Review URL: http://codereview.appspot.com/5516044/
git-svn-id: http://skia.googlecode.com/svn/trunk@2983 2bbb7eff-a529-9590-31e7-b0007b416f81
Diffstat (limited to 'src/animator/SkAnimateActive.cpp')
-rw-r--r-- | src/animator/SkAnimateActive.cpp | 11 |
1 files changed, 8 insertions, 3 deletions
diff --git a/src/animator/SkAnimateActive.cpp b/src/animator/SkAnimateActive.cpp index f429903393..4177aa0568 100644 --- a/src/animator/SkAnimateActive.cpp +++ b/src/animator/SkAnimateActive.cpp @@ -142,9 +142,12 @@ void SkActive::calcDurations(int index) SkAnimateBase* animate = fAnimators[index]; SkMSec duration = animate->dur; SkState& state = fState[index]; - if (state.fMode == SkApply::kMode_immediate || state.fMode == SkApply::kMode_create) + switch (state.fMode) { + case SkApply::kMode_immediate: + case SkApply::kMode_create: duration = state.fSteps ? state.fSteps * SK_MSec1 : 1; -// else if (state.fMode == SkApply::kMode_hold) { + break; +// case SkApply::kMode_hold: { // int entries = animate->entries(); // SkScriptValue value; // value.fOperand = animate->getValues()[entries - 1]; @@ -152,7 +155,9 @@ void SkActive::calcDurations(int index) // bool result = SkScriptEngine::ConvertTo(NULL, SkType_Int, &value); // SkASSERT(result); // duration = value.fOperand.fS32 * SK_MSec1; -// } +// break; +// } + } state.fDuration = duration; SkMSec maxTime = state.fBegin + duration; if (fMaxTime < maxTime) |