[core] factor out RunLoop::wake()

This commit is contained in:
Konstantin Käfer
2018-01-23 14:30:01 -08:00
parent 3ef7dab1a8
commit 78f8fd88b4
5 changed files with 16 additions and 24 deletions

View File

@@ -216,11 +216,8 @@ LOOP_HANDLE RunLoop::getLoopHandle() {
return Get()->impl.get();
}
void RunLoop::push(std::shared_ptr<WorkTask> task) {
withMutex([&] {
queue.push(std::move(task));
impl->wake();
});
void RunLoop::wake() {
impl->wake();
}
void RunLoop::run() {