Merge pull request #4059 from zhaowenlan1779/udp-input-ui

citra_qt: add motion/touch config
This commit is contained in:
James Rowe 2018-08-26 11:56:50 -06:00 committed by GitHub
commit 50270fd791
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
13 changed files with 831 additions and 7 deletions

View file

@ -55,6 +55,15 @@ public:
is_set = false;
}
template <class Duration>
bool WaitFor(const std::chrono::duration<Duration>& time) {
std::unique_lock<std::mutex> lk(mutex);
if (!condvar.wait_for(lk, time, [this] { return is_set; }))
return false;
is_set = false;
return true;
}
template <class Clock, class Duration>
bool WaitUntil(const std::chrono::time_point<Clock, Duration>& time) {
std::unique_lock<std::mutex> lk(mutex);