| 652 | } |
| 653 | |
| 654 | void MainWindow::blankTMate2Display() |
| 655 | { |
| 656 | if (!m_hidEncoder || !m_hidEncoder->isOpen() || !m_hidEncoder->isTMate2()) return; |
| 657 | if (tmate2OverlayActive()) { |
| 658 | restartTMate2IdleTimer(); |
| 659 | return; |
| 660 | } |
| 661 | const int idleMs = tmate2IdleTimeoutMs(); |
| 662 | if (idleMs <= 0) |
| 663 | return; |
| 664 | const qint64 now = QDateTime::currentMSecsSinceEpoch(); |
| 665 | if (m_tmate2LastUserInteractionMs > 0 && |
| 666 | now - m_tmate2LastUserInteractionMs < idleMs) { |
| 667 | m_tmate2IdleTimer.start(static_cast<int>(idleMs - (now - m_tmate2LastUserInteractionMs))); |
| 668 | return; |
| 669 | } |
| 670 | m_tmate2DisplayBlanked = true; |
| 671 | QMetaObject::invokeMethod(m_hidEncoder, [this] { |
| 672 | m_hidEncoder->setTMate2Display(0, 0); |
| 673 | m_hidEncoder->clearTMate2Indicators(); |
| 674 | }); |
| 675 | } |
| 676 | |
| 677 | void MainWindow::triggerTMate2Overlay(TMate2Overlay overlay, int value) |
| 678 | { |
nothing calls this directly
no test coverage detected