1

My app contains only one UISplitViewController. Now I want to add a floating button on top of the window. But it is not possible to use the storyboard to drag a button to the UITableViewController of the master view, because by default, the master view contains only a UITableView.

How can I do it?

enter image description here

T D Nguyen
  • 7,054
  • 4
  • 51
  • 71

1 Answers1

1

You just need to create a new View controller before your split view controller. And in this new controller add the button on top and add the container view to fill the rest of the view.

Storyboard

Then create a segue from container view to Split View Controller by viewDidLoad/embed

enter image description here

That's all!

enter image description here

Yunus Eren Güzel
  • 3,018
  • 11
  • 36
  • 63