diff --git a/MetaballsKit/PreferencesViewController.swift b/MetaballsKit/PreferencesViewController.swift index 82befe2..d533af5 100644 --- a/MetaballsKit/PreferencesViewController.swift +++ b/MetaballsKit/PreferencesViewController.swift @@ -76,23 +76,13 @@ class PreferencesViewController: NSViewController { ]) colorStackView.addArrangedSubview(styleMenu) - var firstColorView: ColorView? = nil - var constraints = [NSLayoutConstraint]() for i in 0..<4 { let colorView = ColorView() colorView.translatesAutoresizingMaskIntoConstraints = false colorView.label.stringValue = "Color \(i+1)" colorStackView.addArrangedSubview(colorView) colorViews.append(colorView) - - if let firstColorView = firstColorView { - let constraint = colorView.widthAnchor.constraint(equalTo: firstColorView.widthAnchor, multiplier: 1) - constraints.append(constraint) - } else { - firstColorView = colorView - } } - NSLayoutConstraint.activate(constraints) self.view = view }