mirror of
https://github.com/rustdesk/rustdesk.git
synced 2025-01-19 08:23:01 +08:00
This commit is contained in:
parent
b0042f29fb
commit
97aa739d69
@ -110,12 +110,16 @@ extern "C" bool MacCheckAdminAuthorization() {
|
||||
}
|
||||
|
||||
extern "C" float BackingScaleFactor(uint32_t display) {
|
||||
NSScreen* s = [NSScreen mainScreen];
|
||||
if (s) return [s backingScaleFactor];
|
||||
/* on my mini mac, display==2, but only 1 screen
|
||||
display -= 1;
|
||||
NSArray<NSScreen *> *screens = [NSScreen screens];
|
||||
if (display >= 0 && display < [screens count]) {
|
||||
NSScreen* s = [screens objectAtIndex:display];
|
||||
if (s) return [s backingScaleFactor];
|
||||
}
|
||||
*/
|
||||
return 1;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user