Skip to content

Commit

Permalink
Fixed linter warnings to chill the Hound
Browse files Browse the repository at this point in the history
  • Loading branch information
mahal committed Oct 10, 2024
1 parent 5457416 commit ca7d7a4
Showing 1 changed file with 5 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -41,10 +41,10 @@ struct InstrumentSFZView: View {
let instrumentParams = conductor.instrument.parameters
let paramsPerLine = horizontalSizeClass == .compact ? 6 : 8
let instrumentParamsChunked = instrumentParams.chunked(into: paramsPerLine)

GeometryReader { geoProxy in
VStack {
let paramRows = ForEach(0..<instrumentParamsChunked.count, id:\.self) { chunkIndex in
let paramRows = ForEach(0..<instrumentParamsChunked.count, id: \.self) { chunkIndex in
HStack {
ForEach(instrumentParamsChunked[chunkIndex], id: \.self) { param in
ParameterRow(param: param)
Expand All @@ -53,7 +53,7 @@ struct InstrumentSFZView: View {
}
// i wanted to do it with verticalSizeClass, but couldn't work it out
if horizontalSizeClass == .compact {
ScrollView {
ScrollView {
paramRows
}
} else {
Expand Down Expand Up @@ -86,14 +86,13 @@ extension Array {
extension NodeParameter: Hashable {
public func hash(into hasher: inout Hasher) {
hasher.combine(def.identifier)
}
}
}

extension NodeParameter: Equatable {
public static func ==(lhs: NodeParameter, rhs: NodeParameter) -> Bool {
public static func == (lhs: NodeParameter, rhs: NodeParameter) -> Bool {
// NodeParameter wraps AUParameter which should
// conform to equtable as they are NSObjects
return lhs.parameter == rhs.parameter
}
}

0 comments on commit ca7d7a4

Please sign in to comment.