Skip to content

Commit

Permalink
Fixed warnings
Browse files Browse the repository at this point in the history
  • Loading branch information
aure committed Jan 28, 2024
1 parent e0240fd commit 715eec0
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion Sources/Controls/Control.swift
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ public struct Control<Content: View>: View {
.onAppear {
rect = proxy.frame(in: .local)
}
.onChange(of: proxy.size) { newValue in
.onChange(of: proxy.size) {
rect = proxy.frame(in: .local)
}
}
Expand Down
4 changes: 2 additions & 2 deletions Sources/Controls/Implementations/IndexedSlider.swift
Original file line number Diff line number Diff line change
Expand Up @@ -40,8 +40,8 @@ public struct IndexedSlider: View {
.offset(x: CGFloat(index) * geo.size.width / CGFloat(labels.count))
.animation(.easeOut, value: index)
}
}.onChange(of: normalValue) { newValue in
index = Int(newValue * 0.99 * Float(labels.count))
}.onChange(of: normalValue) {
index = Int(normalValue * 0.99 * Float(labels.count))
}
}
}
Expand Down
2 changes: 1 addition & 1 deletion Sources/Controls/TwoParameterControl.swift
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,7 @@ public struct TwoParameterControl<Content: View>: View {
.onAppear {
rect = proxy.frame(in: .local)
}
.onChange(of: proxy.size) { newValue in
.onChange(of: proxy.size) {
rect = proxy.frame(in: .local)
}
}
Expand Down

0 comments on commit 715eec0

Please sign in to comment.