Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unable to read window titles on Catalina #278

Closed
koekeishiya opened this issue Oct 9, 2019 · 1 comment
Closed

Unable to read window titles on Catalina #278

koekeishiya opened this issue Oct 9, 2019 · 1 comment
Labels
bug Something isn't working

Comments

@koekeishiya
Copy link
Owner

It is no longer possible to read window titles using the private SLSCopyWindowProperty function for some reason on Catalina. Fix is to return to using the slower AX API instead.

@koekeishiya
Copy link
Owner Author

koekeishiya commented Feb 12, 2020

@dominiklohmann

Just an FYI: All CGWindow APIs seem to require "Screen Recording Permission" as of Catalina to return window titles. This affects the public API such as CGWindowListCopyWindowInfo and the private ones we used previously.

There is a private function that allows an application to request/check for access:

# returns 0 and opens a prompt for access if the application does not have permission
# returns 1 and does not prompt the user if the application already has permission
extern uint8_t SLSRequestScreenCaptureAccess(void);

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant