File tree Expand file tree Collapse file tree 1 file changed +7
-6
lines changed
Expand file tree Collapse file tree 1 file changed +7
-6
lines changed Original file line number Diff line number Diff line change @@ -16,14 +16,14 @@ open class VisualEffectView: UIVisualEffectView {
1616 private let blurEffect = ( NSClassFromString ( " _UICustomBlurEffect " ) as! UIBlurEffect . Type) . init ( )
1717
1818 // MARK: - Public Style API
19-
19+
2020 public enum VisualEffectStyle : Sendable , Equatable {
2121 case none
2222 case systemBlur( UIBlurEffect . Style )
2323 case customBlur
2424 case glass( GlassStyle ) // iOS 26+
2525 }
26-
26+
2727 public enum GlassStyle : Sendable , Equatable {
2828 case regular
2929 case clear
@@ -44,21 +44,21 @@ open class VisualEffectView: UIVisualEffectView {
4444 }
4545
4646 // MARK: - Preserve custom settings across style switches
47-
47+
4848 private struct CustomSnapshot {
4949 var colorTint : UIColor ?
5050 var blurRadius : CGFloat
5151 var saturation : CGFloat
5252 var scale : CGFloat
5353 }
54-
54+
5555 private var customSnapshot = CustomSnapshot (
5656 colorTint: nil ,
5757 blurRadius: 0 ,
5858 saturation: 1 ,
5959 scale: 1
6060 )
61-
61+
6262 /**
6363 Tint color.
6464
@@ -80,7 +80,7 @@ open class VisualEffectView: UIVisualEffectView {
8080
8181 /**
8282 Tint color alpha.
83-
83+
8484 Don't use it unless `colorTint` is not nil.
8585 The default value is 0.0.
8686 */
@@ -187,6 +187,7 @@ private extension VisualEffectView {
187187 self . colorTint = customSnapshot. colorTint
188188 }
189189
190+
190191}
191192
192193// MARK: - Helpers
You can’t perform that action at this time.
0 commit comments