|
|
|||
Location:
QikDocument.h
Link against: qikcore.lib
class CQikDocument : public CEikDocument;
This class provides an extra document layer over the CEikDocument class. This layer is closing down applications when EReleaseRam is received.
MSaveObserver - No description.CBase - Base class for all classes to be instantiated on the heapCApaDocument - Defines basic behaviour for documentsCEikDocument - The base class for all GUI applications' documentsCQikDocument - This class provides an extra document layer over the CEikDocument classDefined in CQikDocument:
CQikDocument(), CreateFileStoreLC(), EditL(), ExternalizeL(), HasChanged(), NewDocumentL(), OpenFileL(), PrintL(), RestoreL(), SaveL(), SaveL(), StoreL(), UpdateTaskNameL(), ValidatePasswordL(), ~CQikDocument()
Inherited from CApaDocument:
Application(),
Capability(),
DetachFromStoreL(),
GlassPictureL(),
Process(),
TCapability,
iContainer
Inherited from CBase:
Delete(),
Extension_(),
operator new()
Inherited from CEikDocument:
AppCaption(),
AppFileMode(),
CreateAppUiL(),
EditStore(),
IsEmpty(),
PrepareToEditL(),
SetAppFileMode(),
SetChanged(),
SetEditStoreL(),
iAppUi,
iEditStore
IMPORT_C CQikDocument(CEikApplication &aApp);
Default constructor. Allocates a new CEikDocument and initialises its references to the associated application and managing process.
|
virtual IMPORT_C void SaveL(MSaveObserver::TSaveType aSaveType);
Saves the document to its current direct file store, marking it as not having changed and saves application data depending on the save type.
This method is called when the system requires the application to save its data. The aSaveType parameter specifies the reason why this is so. The default implementation always calls the parameterless SaveL() overload.
If aSaveType is a request to release memory (MSaveObserver::EReleaseRAM ), the default implementation sends a quit request (EEikCmdExit ) to the AppUi's HandleCommandL() . An application that does not want to quit when there is a memory shortage (e.g. because there is a file download in progress), must therefore override this function. Note that the system will not send a EReleaseRAM event if the application is in the foreground. Note that the event will be sent to a system application and it is up to the system app to decide if it can release memory or not.
If aSaveType indicates that disk space is low MSaveObserver::EReleaseDisk , the function should be overriden to perform any possible application space saving, for example, deleting cached files, or compressing saved data. Please note that if using standard databases it is not recommended to compress saved data when disk space is low as the database will in actuality increase in size, if just for a short moment!
|
virtual IMPORT_C void UpdateTaskNameL(CApaWindowGroupName *aWgName);
Updates the task name.
|
virtual IMPORT_C void NewDocumentL();
Initialises a new default document.
This function calls CEikDocument::NewDocumentL() only.
virtual IMPORT_C CFileStore *CreateFileStoreLC(RFs &aFs, const TDesC &aFileName);
Creates a new file store for a file, creating a new file or overwriting an existing one as necessary. A StoreL() is performed immediately.
|
|
virtual IMPORT_C void EditL(MApaEmbeddedDocObserver *aObserver, TBool aReadOnly=EFalse);
Starts an editing session on an embedded document. This causes the applications UI to be created, and the document is fully restored for editing or viewing.
|
virtual IMPORT_C void PrintL(const CStreamStore &aSourceStore);
Prints a document without opening it for editing. This function is usually called from a shell or file manager application that wants to print the document without opening it fully.
This function is empty. Applications that want to support printing should override this with a function that uses default print parameters.
|
virtual IMPORT_C void SaveL();
Saves the document to its current direct file store, marking it as not having changed. Should be overridden by applications to store application data.
virtual IMPORT_C void StoreL(CStreamStore &aStore, CStreamDictionary &aStreamDic) const;
Stores the documents content and state, recording the identity of any headstreams created.
This function calls the Uikon function CEikDocument::StoreL() , the implementation of which is empty. Applications that wish to persist any data must provide their own version.
|
virtual IMPORT_C void RestoreL(const CStreamStore &aStore, const CStreamDictionary &aStreamDic);
Restores this document from a stream store, setting the documents state and content. Any existing data in the document is lost.
The Uikon implementation of this function is empty. Applications that wish to load any persisted data must provide their own version.
If this function leaves, the document should be rolled back to the state in which it was before the function was called.
|
virtual IMPORT_C void ExternalizeL(RWriteStream &aStream) const;
Externalises the document to the specified write stream.
Calls the Uikon function CEikDocument::ExternalizeL() , the implementation of which is blank.
|
virtual IMPORT_C TBool HasChanged() const;
Gets this documents document-changed flag.
|
virtual IMPORT_C CFileStore *OpenFileL(TBool aDoOpen, const TDesC &aFilename, RFs &aFs);
This function is called by the UI framework during application start-up.
If OpenFileL in EikDocument leave with KErrCorrupt or KErrNotSupported then it deletes the corrupted file and tells the user about it.
|
|
virtual IMPORT_C void ValidatePasswordL() const;
Checks the document password.
The default implementation is empty.