EditControllerDelegate
@objc
public protocol EditControllerDelegate
Use this delegate to handle events that occur in the EditController
.
-
This will be called after
EditController
viewDidLoad. This will only be called once perEditController
.Declaration
Swift
@objc optional func editController(_ editController: EditController, didLoadEditing session: Session)
Parameters
editController
The controller responsible for calling this method.
session
The session the editController will be editing.
-
This will be called at the end of
EditController
viewWillAppear.Declaration
Swift
@objc optional func editController(_ editController: EditController, willBeginEditing session: Session)
Parameters
editController
The controller responsible for calling this method.
session
The session the editController will be editing.
-
This will be called at the end of
EditController
viewDidAppear.Declaration
Swift
@objc optional func editController(_ editController: EditController, didBeginEditing session: Session)
Parameters
editController
The controller responsible for calling this method.
session
The session the editController will be editing.
-
This will be called when the Next button is pressed. You should push on a new controller to the navigation stack or dismiss the controller here.
Attention
You are responsible for destroying the provided session if you do not want it to persist.Declaration
Swift
func editController(_ editController: EditController, didFinishEditing session: Session)
Parameters
editController
The controller responsible for calling this method.
session
The session the controller has finished editing.
-
This will be called when the back button is pressed. If a save dialogue gets presented, this will be called after the dialogue has been dismissed.
Declaration
Swift
@objc optional func editController(_ editController: EditController, didCancelEditing session: Session?)
Parameters
editController
The controller responsible for calling this method.
session
The session the controller has cancelled editing. If the session was not destroyed by the
EditController
it will be passed here. To understand when a session will be destroyed seeshowsSaveDialogue
for more information. If theEditController
was shown by aCameraController
and you destroy the session it will lead to undocumented behavior since the camera depends on the session.