Skip to content
This repository was archived by the owner on Feb 15, 2022. It is now read-only.

Commit 5576541

Browse files
authored
Merge pull request #245 from Lickability/control-state-focused-fix
Small Fix to UIBarButtonItem+TitleTextAttributeStates
2 parents ee2eb9a + bc279eb commit 5576541

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

PinpointKit/PinpointKit/Sources/Core/UIBarButtonItem+TitleTextAttributeStates.swift

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ import UIKit
1010
/// Extends `UIBarButtonItem` to fix an issue with title text attribute propagation.
1111
extension UIBarButtonItem {
1212

13-
/// Sets the specified title text attributes for `.normal`, `.highlighted`, `.disabled`, and `.selected` control states.
13+
/// Sets the specified title text attributes for `.normal`, `.highlighted`, `.disabled`, and `.focused` control states.
1414
///
1515
/// - Parameter titleTextAttributes: A dictionary containing key-value pairs for text attributes.
1616
/// - Note: It should be enough to specify `.normal` and have the attributes propagate, but a bug (radar: 35221407) was introduced in iOS 11 which broke this functionality.
@@ -20,6 +20,6 @@ extension UIBarButtonItem {
2020
setTitleTextAttributes(titleTextAttributes, for: [.normal])
2121
setTitleTextAttributes(titleTextAttributes, for: [.highlighted])
2222
setTitleTextAttributes(titleTextAttributes, for: [.disabled])
23-
setTitleTextAttributes(titleTextAttributes, for: [.selected])
23+
setTitleTextAttributes(titleTextAttributes, for: [.focused])
2424
}
2525
}

0 commit comments

Comments
 (0)