Add a global limit to the number of cached content viewers that scales with the amount of physical memory. Patch by Marria Nazif <marria@gmail.com>. Bug 292965, r=biesi, sr=me.

git-svn-id: svn://10.0.0.236/trunk@180875 18797224-902f-48f8-a5cc-f745e15eee43
This commit is contained in:
bryner%brianryner.com
2005-09-23 18:16:40 +00:00
parent e45eac2ae2
commit ae6e7085e4
15 changed files with 529 additions and 76 deletions

View File

@@ -902,8 +902,15 @@ nsresult nsWebShell::EndPageLoad(nsIWebProgress *aProgress,
if (rootSH && (mLoadType & LOAD_CMD_HISTORY)) {
nsCOMPtr<nsISHistoryInternal> shInternal(do_QueryInterface(rootSH));
if (shInternal)
shInternal->UpdateIndex();
if (shInternal) {
rootSH->GetIndex(&mPreviousTransIndex);
shInternal->UpdateIndex();
rootSH->GetIndex(&mLoadedTransIndex);
#ifdef DEBUG_PAGE_CACHE
printf("Previous index: %d, Loaded index: %d\n\n",
mPreviousTransIndex, mLoadedTransIndex);
#endif
}
}
// Make it look like we really did honestly finish loading the