Fix assert. Bug 236921, r+sr=dbaron, a=chofmann
git-svn-id: svn://10.0.0.236/trunk@154403 18797224-902f-48f8-a5cc-f745e15eee43
This commit is contained in:
parent
d0fbbca5fd
commit
b897a5e2fc
@ -2487,19 +2487,18 @@ const nsStyleBackground*
|
||||
nsCSSRendering::FindNonTransparentBackground(nsStyleContext* aContext,
|
||||
PRBool aStartAtParent /*= PR_FALSE*/)
|
||||
{
|
||||
NS_ASSERTION(aContext, "Cannot find NonTransparentBackground in a null context" );
|
||||
|
||||
const nsStyleBackground* result = nsnull;
|
||||
nsStyleContext* context;
|
||||
nsStyleContext* context = nsnull;
|
||||
if (aStartAtParent) {
|
||||
context = aContext->GetParent();
|
||||
} else {
|
||||
}
|
||||
if (!context) {
|
||||
context = aContext;
|
||||
}
|
||||
NS_ASSERTION(context, "Cannot find NonTransparentBackground in a null context" );
|
||||
|
||||
while (context) {
|
||||
// Have to .get() because some compilers won't match the template
|
||||
// otherwise (they don't look for implicit type conversions while doing
|
||||
// template matching?).
|
||||
result = context->GetStyleBackground();
|
||||
if (0 == (result->mBackgroundFlags & NS_STYLE_BG_COLOR_TRANSPARENT))
|
||||
break;
|
||||
|
||||
@ -2487,19 +2487,18 @@ const nsStyleBackground*
|
||||
nsCSSRendering::FindNonTransparentBackground(nsStyleContext* aContext,
|
||||
PRBool aStartAtParent /*= PR_FALSE*/)
|
||||
{
|
||||
NS_ASSERTION(aContext, "Cannot find NonTransparentBackground in a null context" );
|
||||
|
||||
const nsStyleBackground* result = nsnull;
|
||||
nsStyleContext* context;
|
||||
nsStyleContext* context = nsnull;
|
||||
if (aStartAtParent) {
|
||||
context = aContext->GetParent();
|
||||
} else {
|
||||
}
|
||||
if (!context) {
|
||||
context = aContext;
|
||||
}
|
||||
NS_ASSERTION(context, "Cannot find NonTransparentBackground in a null context" );
|
||||
|
||||
while (context) {
|
||||
// Have to .get() because some compilers won't match the template
|
||||
// otherwise (they don't look for implicit type conversions while doing
|
||||
// template matching?).
|
||||
result = context->GetStyleBackground();
|
||||
if (0 == (result->mBackgroundFlags & NS_STYLE_BG_COLOR_TRANSPARENT))
|
||||
break;
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user