macOS more control over Check system access window
we deploy TeamViewer Host to hundreds of macOS computers. We use silent install (com.teamviewer.teamviewerhostSilentInstaller), automated group assigment, and MDM configuration profile allowing TeamViewer Accessibility and Full Disk Access. Of course there is a one manual step user must do - Screen Recording.
TeamViewer displays this handy window called "Check system access" which is forced frontmost window = it obsures all other windows behind it. This is fine in most situations as we want user to deal with this window, It's reasonable default.
We have a case when we launch our own guide application right after first user login. However this guide application is partically obsured by "Check system access" TeamViewer window. For better/more clear presentation we need an ability to not open/hide/minimalize "Check system access" window. We want to guide user to deal with TeamViewer Screen recording access later using our guide app.
Workaround we discovered:
- Unloading TeamViewer service LaunchAgent (More complex logic for our deployment. We need to load the service back on again.)
- GUI scripting using AppleScript (painfull because codesigning and TCC)