This repository was archived by the owner on Jul 1, 2022. It is now read-only.
File tree Expand file tree Collapse file tree 1 file changed +5
-5
lines changed
ALCameraViewController/ViewController Expand file tree Collapse file tree 1 file changed +5
-5
lines changed Original file line number Diff line number Diff line change @@ -184,8 +184,8 @@ extension CameraViewController {
184184
185185 switch statusBarOrientation {
186186 case . portrait:
187- attributeOne = . top
188- attributeTwo = . bottom
187+ attributeOne = . topMargin
188+ attributeTwo = . bottomMargin
189189 break
190190 case . landscapeRight:
191191 attributeOne = . left
@@ -196,8 +196,8 @@ extension CameraViewController {
196196 attributeTwo = . left
197197 break
198198 default :
199- attributeOne = . bottom
200- attributeTwo = . top
199+ attributeOne = . bottomMargin
200+ attributeTwo = . topMargin
201201 break
202202 }
203203
@@ -401,7 +401,7 @@ extension CameraViewController {
401401 view. autoRemoveConstraint ( flashButtonEdgeConstraint)
402402
403403 let constraintRight = statusBarOrientation == . portrait || statusBarOrientation == . landscapeRight
404- let attribute : NSLayoutAttribute = constraintRight ? . top : . bottom
404+ let attribute : NSLayoutAttribute = constraintRight ? . topMargin : . bottomMargin
405405
406406 flashButtonEdgeConstraint = NSLayoutConstraint (
407407 item: flashButton,
You can’t perform that action at this time.
0 commit comments