| 379 | } |
| 380 | |
| 381 | double EventQueue::getNextTimerTimeout() const |
| 382 | { |
| 383 | // return -1 if no timers, 0 if the top timer has expired, otherwise |
| 384 | // the time until the top timer in the timer priority queue will |
| 385 | // expire. |
| 386 | if (m_timerQueue.empty()) { |
| 387 | return -1.0; |
| 388 | } |
| 389 | if (m_timerQueue.top() <= 0.0) { |
| 390 | return 0.0; |
| 391 | } |
| 392 | return m_timerQueue.top(); |
| 393 | } |
| 394 | |
| 395 | void *EventQueue::getSystemTarget() |
| 396 | { |