IShFileFormatUtilities Struct Reference
[Shell Utilities]
Utilities for handling file formats. Includes file open/save dialog boxes, file format families and lists.
More...
List of all members.
Public Member Functions |
virtual MCCOMErr MCCOMAPI | RegisterFileFamily (IDType inFamily, const TMCString &fileFamilyName)=0 |
virtual MCCOMErr MCCOMAPI | GetFileFamilies (TMCArray< APITypeAndName > &outFamilies, boolean inForOpen)=0 |
virtual MCCOMErr MCCOMAPI | GetFileTypes (TMCArray< APITypeAndName > &outFileTypes, IDType inFamily, boolean inForOpen)=0 |
virtual MCCOMErr MCCOMAPI | GetFileTypes (TMCArray< IDType > &outFileTypes, IDType inFamily, boolean inForOpen)=0 |
virtual void MCCOMAPI | AddFileType (const TMCFileType &inFileType)=0 |
virtual void MCCOMAPI | AddFileTypes (const TMCFileTypeList &inTypesList)=0 |
virtual void MCCOMAPI | LoadResourceFTYP (IDType inCompFamilyID, IDType inCompClassID, ResourceID inResID, MCTypeFamilyID inFileFamily, TMCFileTypeList &outTypeList)=0 |
virtual MCCOMErr MCCOMAPI | OpenFolderDialog (const TMCString &inTitle, IMCFile *file)=0 |
virtual MCCOMErr MCCOMAPI | OpenFileDialog (const TMCString &inTitle, IMCFile *file, TMCArray< IDType > &inFileTypes, IDType &inOutPopupSelection, IDType &outFormat)=0 |
virtual MCCOMErr MCCOMAPI | SaveFileDialog (const TMCString &inTitle, IMCFile *file, TMCArray< IDType > &inFileTypes, IDType &inOutFormat)=0 |
virtual MCCOMErr MCCOMAPI | OpenDocument (const IMCFile *inFile, MCFileTypeID fileType, IMFDocument **outDocument)=0 |
virtual MCCOMErr MCCOMAPI | GetMultipleFiles (const TMCString &inPropmt, IMCFile *startingPath, TMCCountedPtrArray< IMCFile > &outFileList, TMCArray< IDType > &inFileTypes, IDType &inOutPopupSelection)=0 |
virtual const TMCFileType *MCCOMAPI | GetFileTypeByID (MCFileTypeID fileID)=0 |
virtual void MCCOMAPI | GetFileTypesByFamilyID (TMCFileTypeList &fileTypeList, MCTypeFamilyID familyID)=0 |
virtual boolean MCCOMAPI | FindFile (IMCFile *outFile, TMCArray< IDType > &fileTypes, IDType &popupSelection)=0 |
Detailed Description
Utilities for handling file formats. Includes file open/save dialog boxes, file format families and lists.
Member Function Documentation
virtual void MCCOMAPI IShFileFormatUtilities::AddFileType |
( |
const TMCFileType & |
inFileType |
) |
[pure virtual] |
Adds a new file type to the list of types the application handles
- Parameters:
-
| inFileType | The file type to add. |
virtual void MCCOMAPI IShFileFormatUtilities::AddFileTypes |
( |
const TMCFileTypeList & |
inTypesList |
) |
[pure virtual] |
Adds a a list of file types to the list of types the application handles. Note: Use LoadResourceFTYP() to load your type list.
- Parameters:
-
| inTypesList | The list of file types to add. |
This function will try to relocate the file or in last resort ask the user to find it.
Returns the list of available file families
- Parameters:
-
| outFamilies | Returns the list |
| inForOpen | |
Returns a pointer to a TMCFileType by the ID of the file type.
- Parameters:
-
- Returns:
- A pointer to the file type if found, NULL if not.
Returns a list of file type IDs
- Parameters:
-
| outFileTypes | Returns the list of file types in the specified family |
| inFamily | The family of file types to get. (0 for all available families) Call GetFileFamilies() for a list of available file families. |
| inForOpen | Not used at this time. |
Returns a list of file API types and names
- Parameters:
-
| outFileTypes | Returns the list of file types in the specified family |
| inFamily | The family of file types to get. (0 for all available families) Call GetFileFamilies() for a list of available file families. |
| inForOpen | Not used at this time. |
Returns a list of file types that match a given family
- Parameters:
-
| fileTypeList | Returns a list of file types |
| familyID | The ID of the family to query |
Gets a list of one or more file(s) by popping up a multiple file chooser system dialog. Note that the file types can be '****' for all files, a file family ID (ie 'imag'), or a file type ID (ie 'JPEG')
- See also:
- IShFileFormatUtilities::GetFileTypes()
- Parameters:
-
| inPropmt | Prompt to display in the title of |
| startingPath | Pointer to an IMCFile providing the initial directory in which to start the dialog |
| outFileList | An array of pointers to the selected files. |
| inFileTypes | An array of types of files that should be selectable |
| inOutPopupSelection | Default file format to present to the user. This parameter will return the file format actually chosen by the user. |
Loads a FTYP resource into a TMCFileTypeList.
- Parameters:
-
| inCompFamilyID | ID of the component family owning the FTYP resource |
| inCompClassID | ID of the component class owning the FTYP resource |
| inResID | Resource ID of the FTYP to load |
| inFileFamily | ID of the file family to load |
| outTypeList | Returns the list of file types in the family |
Given a file and file type ID, opens a document.
- Parameters:
-
| inFile | Pointer to the file containing the document to open |
| fileType | File type ID of the file |
| outDocument | Returns a pointer to the document opened. |
Opens a system file-open dialog and returns the file selected by the user. Note that the file types can be '****' for all files, a file family ID (ie 'imag'), or a file type ID (ie 'JPEG')
- See also:
- IShFileFormatUtilities::GetFileTypes()
- Parameters:
-
| inTitle | The title of the dialog box that will be opened |
| file | Pointer to the file selected by the user |
| inFileTypes | An array of file types that will be selectable. |
| inOutPopupSelection | The file type selected by the user. On entry, it can contain '****' for all files, the family ID (for instance 'imag') for FileTypeFamily to be used or the ID of the FileType to be used |
| outFormat | The type of the file selected by the user |
virtual MCCOMErr MCCOMAPI IShFileFormatUtilities::OpenFolderDialog |
( |
const TMCString & |
inTitle, |
|
|
IMCFile * |
file | |
|
) |
| | [pure virtual] |
Opens a system folder-open dialog and returns the file selected by the user.
- Parameters:
-
| inTitle | The title of the dialog box that will be opened |
| file | Pointer to the folder selected by the user |
virtual MCCOMErr MCCOMAPI IShFileFormatUtilities::RegisterFileFamily |
( |
IDType |
inFamily, |
|
|
const TMCString & |
fileFamilyName | |
|
) |
| | [pure virtual] |
Registers a new file family
- Parameters:
-
| inFamily | ID type of the family to register (ie 'imag') |
| fileFamilyName | String with the name of the file family (ie "Image Files") |
Opens a system file-save dialog and returns the file and format selected by the user. Note that the file types can be '****' for all files, a file family ID (ie 'imag'), or a file type ID (ie 'JPEG')
- See also:
- IShFileFormatUtilities::GetFileTypes()
- Parameters:
-
| inTitle | The title of the dialog box that will be opened |
| file | Pointer to the file selected by the user |
| inFileTypes | An array of file types that will be selectable. |
| inOutFormat | Default file format to present to the user. This parameter will return the file format actually chosen by the user. |
The documentation for this struct was generated from the following file: