728x90
๋ฐ์ํ
์ฐ์ ์ฒดํฌํฌํ ๋ผ์ด๋ธ๋ฌ๋ฆฌํผ๋ฏธ์ ๋ฉ์๋๋ฅผ ๋ง๋ค์ด์ฃผ๊ณ
๊ฐ ์ํ์ ๋ฐ๋ผ ํด์ผํ ์ผ์ ์ ํด์ค๋ค
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
|
func checkPhotoLibraryPermission() {
let status = PHPhotoLibrary.authorizationStatus()
switch status {
case .authorized:
case .denied, .restricted :
case .notDetermined:
PHPhotoLibrary.requestAuthorization { status in
switch status {
case .authorized:
case .denied, .restricted:
case .notDetermined:
}
}
}
}
http://colorscripter.com/info#e" target="_blank" style="color:#e5e5e5text-decoration:none">Colored by Color Scripter
|
๊ทธ ๋ค์ ๋ทฐ๋๋๋ก๋์ ๋ฉ์๋๋ฅผ ์ถ๊ฐํด์ฃผ๊ณ
์ธํ ์ผ๋ก ์ธ๋ํด์ฃผ๋ ๋ฐฉ๋ฒ์ UIApplication.openSettingsURLString์ ์ด์ฉํด์ค์ settingํ๋ฉด์ผ๋ก ๊ฐ๊ฒํ๋ค.
1
2
3
4
|
if let url = URL(string: UIApplication.openSettingsURLString) {
}
http://colorscripter.com/info#e" target="_blank" style="color:#e5e5e5text-decoration:none">Colored by Color Scripter
|
728x90
๋ฐ์ํ
๋๊ธ