Closed seriouscyrus closed 6 years ago
Never mind, I hand't looked at the demo. It needs to be embedded in a navigation controller
and the (id)sender needs to conform to UIPopoverController protocol which is object of changes/deprecated the moment. When using subclasses of UIButton as sender in example, the navigationController would hide the settings view but show the Title and maybe the Done button if placed. In comparison to CABTMIDICentralViewController and CABTMIDILocalPeripheralViewController where this would work had to specifically use UIButton to get it working properly. Maybe worth mentioning in the LinkKit documentation unless its working like the those both Bluetooth settings i.e.
I believe UIPopoverController
is deprecated in favor of UIPopoverPresentationController
. I see how that functionality could be useful. But might also limit other use cases. So I don't think it should be a requirement.
It should be possible to wrap ABLLinkSettingsViewController
in a UIPopoverPresentationController
though.
Yes it can be wrapped and works when the sender is an UIButton with no subclassing, extension etc. And that is where the ABLLinkSettingsVC is different from CABTMidiCentralVC. Thats not a huge problem, but should be documented or in example code -(IBAction)showAbletonLinkSettingsPopOver(id)sender{} should be (UIButton*)sender{} then..
I'm trying to implement the ABLLinkSettingsViewController through a popover on the iPhone and can't figure out the way to do it.
In the docs, there is a "Done" button in the top right which doesn't appear in my implementation.
Here is my code to present the view controller
And the attached image is the result