File tree 3 files changed +5
-5
lines changed
Sources/ArcGISToolkit/Components/Compass
3 files changed +5
-5
lines changed Original file line number Diff line number Diff line change @@ -50,7 +50,7 @@ Compass:
50
50
` Compass ` has the following modifiers:
51
51
52
52
- ` func compassSize(size: CGFloat) ` - The size of the ` Compass ` , specifying both the width and height of the compass.
53
- - ` func disableAutoHide (_:) ` - Specifies whether the `` Compass `` should automatically hide when the heading is 0.
53
+ - ` func autoHideDisabled (_:) ` - Specifies whether the `` Compass `` should automatically hide when the heading is 0.
54
54
55
55
## Behavior:
56
56
Original file line number Diff line number Diff line change @@ -136,7 +136,7 @@ public extension Compass {
136
136
/// Specifies whether the ``Compass`` should automatically hide when the heading is 0.
137
137
/// - Parameter disable: A Boolean value indicating whether the compass should automatically
138
138
/// hide/show itself when the heading is `0`.
139
- func disableAutoHide ( _ disable: Bool = true ) -> some View {
139
+ func autoHideDisabled ( _ disable: Bool = true ) -> some View {
140
140
var copy = self
141
141
copy. autoHide = !disable
142
142
return copy
Original file line number Diff line number Diff line change @@ -25,7 +25,7 @@ final class CompassTests: XCTestCase {
25
25
var _viewpoint : Viewpoint ? = makeViewpoint ( rotation: initialValue)
26
26
let viewpoint = Binding ( get: { _viewpoint } , set: { _viewpoint = $0 } )
27
27
let compass = Compass ( viewpoint: viewpoint)
28
- . disableAutoHide ( ) as! Compass
28
+ . autoHideDisabled ( ) as! Compass
29
29
XCTAssertFalse ( compass. shouldHide)
30
30
_viewpoint = makeViewpoint ( rotation: finalValue)
31
31
XCTAssertFalse ( compass. shouldHide)
@@ -54,7 +54,7 @@ final class CompassTests: XCTestCase {
54
54
/// `false`.
55
55
func testAutomaticallyHidesNoAutoHide( ) {
56
56
let compass = Compass ( viewpoint: . constant( nil ) )
57
- . disableAutoHide ( ) as! Compass
57
+ . autoHideDisabled ( ) as! Compass
58
58
XCTAssertFalse ( compass. shouldHide)
59
59
}
60
60
@@ -67,7 +67,7 @@ final class CompassTests: XCTestCase {
67
67
/// Verifies that the compass correctly initializes when given only a viewpoint.
68
68
func testInitWithViewpointAndAutoHide( ) {
69
69
let compass = Compass ( viewpoint: . constant( makeViewpoint ( rotation: . zero) ) )
70
- . disableAutoHide ( ) as! Compass
70
+ . autoHideDisabled ( ) as! Compass
71
71
XCTAssertFalse ( compass. shouldHide)
72
72
}
73
73
}
You can’t perform that action at this time.
0 commit comments