Showing the changes to interface/src/Application.cpp (1 of 3 files). Show all
Unified · Split
| @@ -7329,6 +7329,16 @@ bool Application::hasFocus() const { · 7328 unmodified lines | |||
| 7329 | return (QApplication::activeWindow() != nullptr); | 7329 | return (QApplication::activeWindow() != nullptr); |
| 7330 | } | 7330 | } |
| 7331 | 7331 | ||
| 7332 | void Application::setFocus() { | ||
| 7333 | // Note: Windows doesn't allow a user focus to be taken away from another application. Instead, it changes the color of and | ||
| 7334 | // flashes the taskbar icon. | ||
| 7335 | auto window = qApp->getWindow(); | ||
| 7336 | window->activateWindow(); | ||
| 7337 | |||
| 7338 | // Do NOT do the following because it takes focus away from the _displayPlugin. | ||
| 7339 | //window->setFocus(); | ||
| 7340 | } | ||
| 7341 | |||
| 7332 | void Application::setMaxOctreePacketsPerSecond(int maxOctreePPS) { | 7342 | void Application::setMaxOctreePacketsPerSecond(int maxOctreePPS) { |
| 7333 | if (maxOctreePPS != _maxOctreePPS) { | 7343 | if (maxOctreePPS != _maxOctreePPS) { |
| 7334 | _maxOctreePPS = maxOctreePPS; | 7344 | _maxOctreePPS = maxOctreePPS; |