private let anchorageRepairManager = AnchorageRepairManager.default
- @IBOutlet var screenshotButton: NSButton!
+ @IBOutlet private var screenshotButton: NSButton!
@objc dynamic var repairTime: NSNumber?
var controlSize: NSControl.ControlSize = .regular {
willSet {
- if controlSize == newValue { return }
+
+ if controlSize == newValue {
+
+ return
+ }
var frame = view.frame
frame.size.height = (newValue == .regular ? type(of: self).regularHeight : type(of: self).smallHeight)
view.frame = frame
AppDelegate.shared.addCounterUpdate { [weak self] in
- guard let `self` = self else { return }
+ guard let `self` = self else {
+
+ return
+ }
self.repairTime = self.calcRepairTime()
}
private func refleshTrackingArea() {
- view.trackingAreas
- .forEach { view.removeTrackingArea($0) }
+ view.trackingAreas.forEach(view.removeTrackingArea)
trackingArea = NSTrackingArea(rect: screenshotButton.frame,
options: [.mouseEnteredAndExited, .activeInActiveApp],
owner: self,