blob: 9ede02683ebf33c3788cddc723fedbdf8c5214f1 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
|
#include "rotate_screen_task.hpp"
#include "framework.hpp"
RotateScreenTask::RotateScreenTask(Framework * framework,
double startAngle,
double endAngle,
double speed)
: anim::AngleInterpolation(startAngle,
endAngle,
speed,
m_outAngle),
m_framework(framework)
{
}
void RotateScreenTask::OnStep(double ts)
{
anim::AngleInterpolation::OnStep(ts);
m_framework->GetNavigator().SetAngle(m_outAngle);
}
void RotateScreenTask::OnEnd(double ts)
{
anim::AngleInterpolation::OnEnd(ts);
m_framework->GetNavigator().SetAngle(m_outAngle);
}
|