Skip to content

fix: replace CGPreflightScreenCaptureAccess with SCShareableContent on macOS Sequoia#219

Open
hsjin500 wants to merge 1 commit intoJerryZLiu:mainfrom
hsjin500:fix/screen-recording-permission-check
Open

fix: replace CGPreflightScreenCaptureAccess with SCShareableContent on macOS Sequoia#219
hsjin500 wants to merge 1 commit intoJerryZLiu:mainfrom
hsjin500:fix/screen-recording-permission-check

Conversation

@hsjin500
Copy link
Copy Markdown

Summary

  • macOS Sequoia에서 CGPreflightScreenCaptureAccess()가 TCC 권한이 허용(auth_value=2)되어 있어도 false를 반환하는 버그 수정
  • SCShareableContent.excludingDesktopWindows() try/catch 패턴으로 교체하여 실제 권한 상태를 신뢰성 있게 확인
  • Settings "Run status check"에서 "Screen recording permission missing"으로 잘못 표시되는 문제 해결

Changed files (3)

  • StorageSettingsViewModel.swift: CGPreflightScreenCaptureAccess()SCShareableContent try/catch
  • ScreenRecordingPermissionView.swift: .onAppear, .onReceive, requestPermission() 3곳 교체 (동기→비동기)
  • OnboardingFlow.swift: 불필요한 CGPreflightScreenCaptureAccess() guard 제거, SCShareableContent 결과에만 의존

Test plan

  • Xcode 빌드 성공 확인 (verified locally)
  • Settings → "Run status check" → "Screen recording permission granted" 표시 확인
  • Onboarding flow에서 권한 부여 후 정상 진행 확인

🤖 Generated with Claude Code

…ableContent check

macOS Sequoia에서 CGPreflightScreenCaptureAccess()가 TCC 권한이 허용되어 있어도
false를 반환하는 버그 수정. SCShareableContent.excludingDesktopWindows() try/catch
패턴으로 교체하여 실제 권한 상태를 신뢰성 있게 확인하도록 변경.

- StorageSettingsViewModel: Settings 상태 체크에서 올바른 권한 표시
- ScreenRecordingPermissionView: onAppear/onReceive/requestPermission 3곳 교체
- OnboardingFlow: 불필요한 CGPreflight guard 제거, SCShareableContent 결과에 의존

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant