Instance Method


Asks your extension for edited asset data to finish the editing session.



- (void)finishContentEditingWithCompletionHandler:(void (^)(PHContentEditingOutput *))completionHandler;



A block for your extension to call when you have finished editing.

The block takes the following parameter:


The PHContentEditingOutput object you created and populated before calling the completion handler.


Photos calls this method when the user chooses to end the editing session. Your extension view controller should:

  1. Disable UI elements to prevent the user from editing further while you complete the remaining steps on a background queue.

  2. Create a PHContentEditingOutput object from the PHContentEditingInput object that Photos provided to your extension in the startContentEditingWithInput:placeholderImage: method.

    Use the content editing output to store the rendered photo or video data from the user’s edits and a PHAdjustmentData object describing the edits.

  3. Call the completionHandler block with your content editing output, to notify Photos that the edit is complete.

  4. After the completionHandler block finishes executing, you may safely clean up any data or files related to your edit.

See Also

Performing an Edit

- startContentEditingWithInput:placeholderImage:

Tells your extension that asset data is available for editing.