r=ccarlen, sr=rpotts on the mozilla/docshell/* and mozilla/embedding/* mods (81263). embedding apps can now control whether or not images are loaded in a specific nsWebBrowser window. This is done via nsIWebBrowserSetup. shaver@mozilla.org provided a nsWebBrowserContentPolicy implementation which registers for, and responds to, nsIContentPolicy callbacks giving nsIContentPolicies an opportunity to cancel a load or the processing of an element. processing isn't hooked up yet, and some of the content policy types in the switch statement won't become relevant until further nsIContentPolicy hookup is done. Those cases are handled inside the docshell/webshell until the content policy hook-up is made.
git-svn-id: svn://10.0.0.236/trunk@95622 18797224-902f-48f8-a5cc-f745e15eee43
This commit is contained in:
@@ -158,6 +158,7 @@ nsDocShell::nsDocShell():
|
||||
mAllowJavascript(PR_TRUE),
|
||||
mAllowMetaRedirects(PR_TRUE),
|
||||
mAllowSubframes(PR_TRUE),
|
||||
mAllowImages(PR_TRUE),
|
||||
mAppType(nsIDocShell::APP_TYPE_UNKNOWN),
|
||||
mBusyFlags(BUSY_FLAGS_NONE),
|
||||
mEODForCurrentDocument(PR_FALSE),
|
||||
@@ -1154,6 +1155,20 @@ NS_IMETHODIMP nsDocShell::SetAllowSubframes(PRBool aAllowSubframes)
|
||||
return NS_OK;
|
||||
}
|
||||
|
||||
NS_IMETHODIMP nsDocShell::GetAllowImages(PRBool * aAllowImages)
|
||||
{
|
||||
NS_ENSURE_ARG_POINTER(aAllowImages);
|
||||
|
||||
*aAllowImages = mAllowImages;
|
||||
return NS_OK;
|
||||
}
|
||||
|
||||
NS_IMETHODIMP nsDocShell::SetAllowImages(PRBool aAllowImages)
|
||||
{
|
||||
mAllowImages = aAllowImages;
|
||||
return NS_OK;
|
||||
}
|
||||
|
||||
NS_IMETHODIMP
|
||||
nsDocShell::GetDocShellEnumerator(PRInt32 aItemType, PRInt32 aDirection, nsISimpleEnumerator **outEnum)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user