// replace nsString::Recycle with nsMemory::Free
java/dom/jni/org_mozilla_dom_events_MouseEventImpl.cpp
java/dom/jni/org_mozilla_dom_events_UIEventImpl.cpp
java/dom/jni/org_mozilla_dom_events_EventImpl.cpp
java/dom/jni/org_mozilla_dom_ProcessingInstructionImpl.cpp
java/dom/jni/org_mozilla_dom_NodeImpl.cpp
java/dom/jni/org_mozilla_dom_NamedNodeMapImpl.cpp
java/dom/jni/org_mozilla_dom_ElementImpl.cpp
java/dom/jni/org_mozilla_dom_DOMImplementationImpl.cpp
java/dom/jni/org_mozilla_dom_DocumentImpl.cpp
java/dom/jni/org_mozilla_dom_CharacterDataImpl.cpp
java/dom/jni/org_mozilla_dom_AttrImpl.cpp
java/dom/jni/javaDOMEventsGlobals.cpp
// On*DocumentLoad() now takes an nsIRequest instead of an nsIChannel.
// nsIChannel extends nsIRequest.
java/dom/src/nsJavaDOMImpl.cpp
java/dom/src/nsJavaDOMImpl.h
java/dom/src/nsIJavaDOM.h
// nsIChannel instances replaced with nsIRequest. Removed ShowModal(),
// ExitModalLoop(), FindNamedBrowserItem(). Parameter changes for
// {Set,Get}Persistence(). Add DestroyBrowserWindow(), IsWindowModal().
// supports weak references
java/webclient/src_moz/CBrowserContainer.h
java/webclient/src_moz/CBrowserContainer.cpp
// GetProfileList now returns an array of profile names. Need to use
// nsIProfileInternal instead of nsIProfile for StartupWithArgs.
java/webclient/src_moz/NativeEventThread.cpp
// Remove -lxpfelocation_s
java/webclient/src_moz/Makefile.in
// Don't include appfilelocprovider_s
java/webclient/src_moz/Makefile.win
// Don't assert thread safe, cause we are thread safe
java/webclient/src_moz/InputStreamShim.cpp
git-svn-id: svn://10.0.0.236/trunk@91060 18797224-902f-48f8-a5cc-f745e15eee43
This commit is contained in:
@@ -35,6 +35,7 @@
|
||||
#include "nsEmbedAPI.h" // for NS_InitEmbedding
|
||||
|
||||
#include "nsIProfile.h" // for the profile manager
|
||||
#include "nsIProfileInternal.h" // for the profile manager
|
||||
#include "nsICmdLineService.h" // for the cmdline service to give to the
|
||||
// profile manager.
|
||||
|
||||
@@ -510,24 +511,26 @@ void DoMozInitialization(WebShellInitContext * initContext)
|
||||
int i, argc = 0;
|
||||
argv[0] = strdup(gBinDir);
|
||||
if (numProfiles > 1) {
|
||||
PRUnichar * Names;
|
||||
rv = profile->GetProfileList(&Names);
|
||||
// PENDING(edburns): fix for 70656. Really we should have a way
|
||||
// for the embedding app to specify which profile to use.
|
||||
// For now we just get the name of the first profile.
|
||||
PRUnichar **Names;
|
||||
PRUint32 NamesLen = 0;
|
||||
rv = profile->GetProfileList(&NamesLen, &Names);
|
||||
argv[1] = strdup("-p");
|
||||
char * temp = new char[100]; // de-allocated in following for loop
|
||||
for (i = 0; i<100; i++) {
|
||||
if ((char) Names[i] != ',')
|
||||
temp[i] = (char) Names[i];
|
||||
else {
|
||||
temp[i] = '\0';
|
||||
break;
|
||||
if (NS_SUCCEEDED(rv)) {
|
||||
PR_ASSERT(NamesLen >= 1);
|
||||
// PENDING(edburns): fix for 70656. Really we should have a way
|
||||
// for the embedding app to specify which profile to use.
|
||||
// For now we just get the name of the first profile.
|
||||
char * temp = new char[100]; // de-allocated in following for loop
|
||||
for (i = 0; Names[0][i] != '\0'; i++) {
|
||||
temp[i] = (char) Names[0][i];
|
||||
}
|
||||
nsMemory::Free(Names);
|
||||
argv[2] = temp;
|
||||
argc = 3;
|
||||
}
|
||||
nsCRT::free(Names);
|
||||
argv[2] = temp;
|
||||
argc = 3;
|
||||
else {
|
||||
argv[2] = strdup("default");
|
||||
}
|
||||
printf("debug: edburns: argv[1]: %s argv[2]: %s\n", argv[1],
|
||||
argv[2]);
|
||||
}
|
||||
@@ -542,8 +545,15 @@ void DoMozInitialization(WebShellInitContext * initContext)
|
||||
::util_ThrowExceptionToJava(env, "Can't initialize nsICmdLineService.");
|
||||
return;
|
||||
}
|
||||
rv = profile->StartupWithArgs(cmdLine);
|
||||
if (NS_FAILED(rv)) {
|
||||
nsCOMPtr<nsIProfileInternal> profileInt = do_QueryInterface(profile);
|
||||
if (profileInt) {
|
||||
rv = profileInt->StartupWithArgs(cmdLine);
|
||||
if (NS_FAILED(rv)) {
|
||||
::util_ThrowExceptionToJava(env, "Can't statrup nsIProfile service.");
|
||||
return;
|
||||
}
|
||||
}
|
||||
else {
|
||||
::util_ThrowExceptionToJava(env, "Can't statrup nsIProfile service.");
|
||||
return;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user