Skip to content

Commit

Permalink
Create UIScreenExtension.swift
Browse files Browse the repository at this point in the history
  • Loading branch information
ivanvorobei committed Nov 24, 2024
1 parent 8282e6e commit 2304815
Showing 1 changed file with 11 additions and 0 deletions.
11 changes: 11 additions & 0 deletions Sources/SwiftBoost/UIKit/Extensions/UIScreenExtension.swift
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
import UIKit

public extension UIScreen {

var displayCornerRadius: CGFloat {
guard let cornerRadius = self.value(forKey: "_displayCornerRadius") as? CGFloat else {
return .zero
}
return cornerRadius
}
}

0 comments on commit 2304815

Please sign in to comment.