Skip to content

Single Action Button

FUISingleActionButton

open class FUISingleActionButton: FUIButton

Button component used in FUISingleActionAccessoryView.

This view appears as the accessoryViewto the FUIObjectTableViewCell.

Usage

1
2
3
4
5
6
7
8
9
let singleActionButton = FUISingleActionButton()
singleActionButton.setTitle("Follow", for: .normal)
singleActionButton.setTitle("Unfollow", for: .selected)
singleActionButton.titleLabel?.preferredMaxLayoutWidth = 75
singleActionButton.isPersistentSelection = true
singleActionButton.isPreservingPreferredMaxLayoutWidth = true
singleActionButton.didSelectHandler = { btn in
   print("Button Selected")
}

Last update: December 8, 2020