mirror of
https://github.com/AyuGram/AyuGramDesktop.git
synced 2025-06-07 15:43:55 +02:00
Fallback to D-Bus methods if XCB-based LastUserInputTime failed
This commit is contained in:
parent
983d9e6eee
commit
638ea3111f
1 changed files with 4 additions and 1 deletions
|
@ -1013,7 +1013,10 @@ QImage GetImageFromClipboard() {
|
||||||
|
|
||||||
std::optional<crl::time> LastUserInputTime() {
|
std::optional<crl::time> LastUserInputTime() {
|
||||||
if (!IsWayland()) {
|
if (!IsWayland()) {
|
||||||
return XCBLastUserInputTime();
|
const auto xcbResult = XCBLastUserInputTime();
|
||||||
|
if (xcbResult.has_value()) {
|
||||||
|
return xcbResult;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
#ifndef DESKTOP_APP_DISABLE_DBUS_INTEGRATION
|
#ifndef DESKTOP_APP_DISABLE_DBUS_INTEGRATION
|
||||||
|
|
Loading…
Add table
Reference in a new issue