void MoveEvents() { for (Event ev; s_ts_queue.Pop(ev);) { ev.fifo_order = s_event_fifo_id++; s_event_queue.emplace_back(std::move(ev)); std::push_heap(s_event_queue.begin(), s_event_queue.end(), std::greater<Event>()); } }
void MoveEvents() { BaseEvent sevt; while (tsQueue.Pop(sevt)) { Event *evt = GetNewEvent(); evt->time = sevt.time; evt->userdata = sevt.userdata; evt->type = sevt.type; AddEventToQueue(evt); } }