Back to index
|void||initEmbedding (File aLibXULDirectory, File aAppDirectory, IAppFileLocProvider aAppDirProvider) throws XPCOMException|
|Initializes libXUL for embedding purposes. |
|Terminates libXUL embedding. |
|ProfileLock||lockProfileDirectory (File aDirectory) throws XPCOMException|
|Lock a profile directory using platform-specific semantics. |
|Fire notifications to inform the toolkit about a new profile. |
Initializes libXUL for embedding purposes.
NOTE: This function must be called from the "main" thread.
NOTE: At the present time, this function may only be called once in a given process. Use
termEmbedding to clean up and free resources allocated by
|aLibXULDirectory||The directory in which the libXUL shared library was found.|
|aAppDirectory||The directory in which the application components and resources can be found. This will map to the "resource:app" directory service key.|
|aAppDirProvider||A directory provider for the application. This provider will be aggregated by a libXUL provider which will provide the base required GRE keys.|
|XPCOMException||if a failure occurred during initialization|
Lock a profile directory using platform-specific semantics.
|aDirectory||The profile directory to lock.|
releasemethod, or by the termination of the JVM, whichever comes first.
|XPCOMException||if a failure occurred|
Fire notifications to inform the toolkit about a new profile.
This method should be called after
initEmbedding if the embedder wishes to run with a profile.
Normally the embedder should call
lockProfileDirectory to lock the directory before calling this method.
NOTE: There are two possibilities for selecting a profile:
initEmbedding. The aAppDirProvider object passed to
initEmbeddingshould provide the NS_APP_USER_PROFILE_50_DIR key, and may also provide the following keys:
notifyProfileshould be called immediately after
initEmbedding. Component registration information will be stored in the profile and JS components may be stored in the fastload cache.
initEmbedding. In this case the embedder must install a directory service provider which provides NS_APP_USER_PROFILE_50_DIR and optionally NS_APP_USER_PROFILE_LOCAL_50_DIR. Component registration information will be stored in the application directory and JS components will not fastload.