|
YSTest
PreAlpha_b400_20130424
The YSLib Test Project
|
输入计时器。 更多...
#include <ygui.h>

Public 类型 | |
| enum | HeldStateType { Free = 0, Pressed = 1, Held = 2 } |
| 输入保持状态。 更多... | |
| typedef Timers::Duration | Duration |
Public 成员函数 | |
| InputTimer (const Duration &=Timers::TimeSpan(1000U)) | |
| void | Delay (const Duration &d) |
| 延迟。 | |
| bool | Refresh (HeldStateType &, const Duration &=Timers::TimeSpan(240), const Duration &=Timers::TimeSpan(120)) |
| 重复检测输入接触保持状态。 | |
| void | Reset () |
| 复位状态。 | |
Private 属性 | |
| Timers::Timer | timer |
| InputTimer::InputTimer | ( | const Duration & | d = Timers::TimeSpan(1000U) | ) |
| bool InputTimer::Refresh | ( | HeldStateType & | s, |
| const Duration & | initial_delay = Timers::TimeSpan(240), |
||
| const Duration & | repeated_delay = Timers::TimeSpan(120) |
||
| ) |
重复检测输入接触保持状态。
参考 YSLib::Activate(),Free,Held,Pressed,YSLib::Timers::Timer::Refresh(),YSLib::Timers::Timer::SetInterval(),timer , 以及 YB_UNLIKELY.

| void InputTimer::Reset | ( | ) |
复位状态。
参考 Deactivate(),YSLib::Timers::Timer::SetInterval() , 以及 timer.
参考自 YSLib::UI::GUIState::Reset() , 以及 YSLib::UI::GUIState::ResetHeldState().


|
private |