Skip to content

Commit

Permalink
Implement initWithCoder so the record button can be used from a story…
Browse files Browse the repository at this point in the history
…board
  • Loading branch information
aelavell committed Feb 13, 2017
1 parent a713603 commit 00ea45d
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion RecordButton.swift
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,13 @@
}

required init?(coder aDecoder: NSCoder) {
fatalError("init(coder:) has not been implemented")
super.init(coder: aDecoder)

self.addTarget(self, action: #selector(RecordButton.didTouchDown), for: .touchDown)
self.addTarget(self, action: #selector(RecordButton.didTouchUp), for: .touchUpInside)
self.addTarget(self, action: #selector(RecordButton.didTouchUp), for: .touchUpOutside)

self.drawButton()
}


Expand Down

0 comments on commit 00ea45d

Please sign in to comment.