mirror of
https://github.com/MacPass/MacPass.git
synced 2025-12-21 02:19:24 +00:00
Updated documentation on export plugin
This commit is contained in:
@@ -147,9 +147,32 @@ FOUNDATION_EXPORT NSString *const MPPluginDescriptionInfoDictionaryKey;
|
||||
@protocol MPExportPlugin <NSObject>
|
||||
|
||||
@required
|
||||
|
||||
/**
|
||||
Called by the host to update a menu item for exporting.
|
||||
You are supposed to update the title to something meaningfull.
|
||||
Target and action will get set by host, so do not rely on them
|
||||
|
||||
@param item MenuItem that will be used to export via the plugin
|
||||
*/
|
||||
- (void)prepareExportMenuItem:(NSMenuItem *)item;
|
||||
|
||||
/**
|
||||
Called by the host when an export is about to happen.
|
||||
Update the panel to work for all the files and formats you can export
|
||||
|
||||
@param panel The panel used to select the export destination
|
||||
*/
|
||||
- (void)prepareSavePanel:(NSSavePanel *)panel;
|
||||
/**
|
||||
This will get called when the save panel is closed by the user.
|
||||
You should retrieve any results from the panel and act accordingly.
|
||||
|
||||
If you need custom UI in the process, you can show them here.
|
||||
For example, if a CSV export might need user input to configure its output this is the place to show it.
|
||||
|
||||
@param tree The current tree to be exported
|
||||
@param panel The save panel that was used to specify the export destination
|
||||
*/
|
||||
- (void)exportTree:(KPKTree *)tree forRunningSavePanel:(NSSavePanel *)panel;
|
||||
|
||||
@end
|
||||
|
||||
Reference in New Issue
Block a user