Functions


CanSaveFileType
Filter file types
CompleteSaveAction
Called after a Save or Save As operation
DocumentTypeName
Return the document type's name, corresponding to an entry in the application's Info.plist file.
FileCreator
Return the 4-byte file creator for document files.
FileType
Return the 4-byte file type for document files.
FinishSaveAs
Handle the results of the Save As dialog
ShouldSave
Determine if saving is allowed
ShowSearchText
Display the text from a Spotlight search

CanSaveFileType

Filter file types
protected

virtual bool CanSaveFileType( const ACFString &inTypeName) const
Discussion

Determine if the given file type is currently available for saving. Called by GenerateSaveTypes.

function result
False to exclude the type from the file types list.

CompleteSaveAction

Called after a Save or Save As operation
protected

virtual void CompleteSaveAction();
Discussion

If the document was being saved before closing, this method finishes by deleting the document.


DocumentTypeName

Return the document type's name, corresponding to an entry in the application's Info.plist file.
public

virtual ACFString DocumentTypeName() const;
Discussion

The default implementation returns the first type listed in the Info.plist file.

function result
The type name

FileCreator

Return the 4-byte file creator for document files.
public

virtual OSType FileCreator();
Discussion

The default implementation returns the creator type from the Info.plist file.


FileType

Return the 4-byte file type for document files.
public

virtual OSType FileType();
Discussion

The default implementation returns the first OSType listed in the Info.plist dictionary, using DocumentTypeName() to look up the document info.


FinishSaveAs

Handle the results of the Save As dialog
protected

virtual void FinishSaveAs( ANavReply &inReply);

ShouldSave

Determine if saving is allowed
protected

virtual bool ShouldSave()
Discussion

For example, an application in demo mode would return false from this function if saving is restricted.

function result
True if saving is allowed.

ShowSearchText

Display the text from a Spotlight search
protected

virtual void ShowSearchText( const std::string &inSearchText)
Discussion

This method is called from Initialize() when a document was opened from a Spotlight search.

Parameter Descriptions
inSearchText
The text from the Spotlight search.

(Last Updated October 06, 2006)