mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-11-25 05:41:12 +00:00
Bug 70714 - visited link doesn't change color in embedding apps. The patch turns on the building of the embed-lite component which implements global history with less footprint and is exported to Embed dist. r=chak/sr=alecf
This commit is contained in:
parent
720143a97b
commit
19f4beea9f
@ -25,6 +25,6 @@ VPATH = @srcdir@
|
||||
|
||||
include $(DEPTH)/config/autoconf.mk
|
||||
|
||||
DIRS = base components browser
|
||||
DIRS = base components browser lite
|
||||
|
||||
include $(topsrcdir)/config/rules.mk
|
||||
|
@ -76,6 +76,7 @@ endif
|
||||
fi
|
||||
$(NSINSTALL) -t $(srcdir)/installed-chrome.txt $(DIST)/Embed/chrome
|
||||
$(NSINSTALL) -t $(srcdir)/readme.html $(DIST)/Embed
|
||||
$(NSINSTALL) -t $(topsrcdir)/embedding/lite/$(LIB_PREFIX)embed_lite$(DLL_SUFFIX) $(DIST)/Embed/components
|
||||
ifeq ($(OS_ARCH),WINNT)
|
||||
ifeq ($(WINAPP),mfcembed)
|
||||
$(NSINSTALL) -t $(DIST)/bin/mfcembed.exe $(DIST)/Embed
|
||||
|
@ -40,6 +40,7 @@ REQUIRES = xpcom \
|
||||
xpconnect \
|
||||
js \
|
||||
xuldoc \
|
||||
appcomps \
|
||||
$(NULL)
|
||||
|
||||
CPPSRCS = \
|
||||
@ -49,7 +50,7 @@ CPPSRCS = \
|
||||
$(NULL)
|
||||
|
||||
# bring in the chrome protocol handler
|
||||
LOBJS = $(topsrcdir)/rdf/chrome/src/nsChromeProtocolHandler.$(OBJ_SUFFIX)
|
||||
# LOBJS = $(topsrcdir)/rdf/chrome/src/nsChromeProtocolHandler.$(OBJ_SUFFIX)
|
||||
|
||||
|
||||
LOCAL_INCLUDES = -I$(DEPTH)/rdf/chrome/src
|
||||
|
@ -216,7 +216,6 @@ nsEmbedChromeRegistry::ReadChromeRegistry()
|
||||
nsresult
|
||||
nsEmbedChromeRegistry::ProcessNewChromeBuffer(char* aBuffer, PRInt32 aLength)
|
||||
{
|
||||
nsresult rv = NS_OK;
|
||||
while (aLength > 0) {
|
||||
PRInt32 processedBytes = ProcessChromeLine(aBuffer, aLength);
|
||||
aBuffer += processedBytes;
|
||||
@ -347,17 +346,13 @@ nsEmbedChromeRegistry::Canonify(nsIURI* aChromeURI)
|
||||
}
|
||||
|
||||
NS_IMETHODIMP
|
||||
nsEmbedChromeRegistry::ConvertChromeURL(nsIURI* aChromeURL, char** aResult)
|
||||
nsEmbedChromeRegistry::ConvertChromeURL(nsIURI* aChromeURL, nsACString& aResult)
|
||||
{
|
||||
nsresult rv;
|
||||
|
||||
nsCAutoString finalURL;
|
||||
rv = aChromeURL->GetSpec(finalURL);
|
||||
rv = aChromeURL->GetSpec(aResult);
|
||||
if (NS_FAILED(rv)) return rv;
|
||||
|
||||
*aResult = ToNewCString(finalURL);
|
||||
if (!*aResult) return NS_ERROR_OUT_OF_MEMORY;
|
||||
|
||||
return NS_OK;
|
||||
}
|
||||
|
||||
|
@ -41,7 +41,7 @@
|
||||
#include "nsIObserverService.h"
|
||||
#include "nsWeakReference.h"
|
||||
#include "nsAppDirectoryServiceDefs.h"
|
||||
#include "nsHashTable.h"
|
||||
#include "nsHashtable.h"
|
||||
#include "nsInt64.h"
|
||||
#include "prtypes.h"
|
||||
#include "nsFixedSizeAllocator.h"
|
||||
@ -93,7 +93,7 @@ public:
|
||||
{ mWritten = PR_TRUE; }
|
||||
|
||||
// Memory management stuff
|
||||
static void* operator new(size_t size);
|
||||
static void* operator new(size_t size) CPP_THROW_NEW;
|
||||
static void operator delete(void *p, size_t size);
|
||||
|
||||
// Must be called when done with all HistoryEntry objects
|
||||
@ -111,7 +111,7 @@ nsFixedSizeAllocator *HistoryEntry::sPool;
|
||||
|
||||
//*****************************************************************************
|
||||
|
||||
void* HistoryEntry::operator new(size_t size)
|
||||
void* HistoryEntry::operator new(size_t size) CPP_THROW_NEW
|
||||
{
|
||||
if (size != sizeof(HistoryEntry))
|
||||
return ::operator new(size);
|
||||
@ -168,9 +168,7 @@ NS_IMPL_ISUPPORTS3(nsEmbedGlobalHistory, nsIGlobalHistory, nsIObserver, nsISuppo
|
||||
nsEmbedGlobalHistory::nsEmbedGlobalHistory() :
|
||||
mDataIsLoaded(PR_FALSE), mEntriesAddedSinceFlush(0),
|
||||
mURLTable(nsnull)
|
||||
{
|
||||
NS_INIT_REFCNT();
|
||||
|
||||
{
|
||||
LL_I2L(mExpirationInterval, kDefaultExpirationIntervalDays);
|
||||
LL_MUL(mExpirationInterval, mExpirationInterval, kMSecsPerDay);
|
||||
}
|
||||
|
@ -87,7 +87,7 @@ protected:
|
||||
|
||||
protected:
|
||||
PRBool mDataIsLoaded;
|
||||
PRUint32 mEntriesAddedSinceFlush;
|
||||
PRInt32 mEntriesAddedSinceFlush;
|
||||
nsCOMPtr<nsILocalFile> mHistoryFile;
|
||||
nsHashtable *mURLTable;
|
||||
PRInt64 mExpirationInterval;
|
||||
|
@ -42,27 +42,27 @@
|
||||
#include "nsEmbedGlobalHistory.h"
|
||||
#include "nsChromeProtocolHandler.h"
|
||||
|
||||
NS_GENERIC_FACTORY_CONSTRUCTOR_INIT(nsEmbedChromeRegistry, Init)
|
||||
//NS_GENERIC_FACTORY_CONSTRUCTOR_INIT(nsEmbedChromeRegistry, Init)
|
||||
NS_GENERIC_FACTORY_CONSTRUCTOR_INIT(nsEmbedGlobalHistory, Init)
|
||||
|
||||
static const nsModuleComponentInfo components[] =
|
||||
{
|
||||
#if 1 // Don't hook up until implementation is finished
|
||||
#if 0 // Don't hook up until implementation is finished
|
||||
{ "Chrome Registry",
|
||||
NS_EMBEDCHROMEREGISTRY_CID,
|
||||
"@mozilla.org/chrome/chrome-registry;1",
|
||||
nsEmbedChromeRegistryConstructor,
|
||||
},
|
||||
{ "Chrome Protocol Handler",
|
||||
NS_CHROMEPROTOCOLHANDLER_CID,
|
||||
NS_NETWORK_PROTOCOL_CONTRACTID_PREFIX "chrome",
|
||||
nsChromeProtocolHandler::Create
|
||||
},
|
||||
#endif
|
||||
{ "Global History",
|
||||
NS_EMBEDGLOBALHISTORY_CID,
|
||||
"@mozilla.org/browser/global-history;1",
|
||||
nsEmbedGlobalHistoryConstructor,
|
||||
},
|
||||
{ "Chrome Protocol Handler",
|
||||
NS_CHROMEPROTOCOLHANDLER_CID,
|
||||
NS_NETWORK_PROTOCOL_CONTRACTID_PREFIX "chrome",
|
||||
nsChromeProtocolHandler::Create
|
||||
}
|
||||
};
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user