Bug 1000875 - Add invalidation debugging annotations for changes of a layer's forced background color. r=roc

This commit is contained in:
Markus Stange 2014-05-05 10:26:28 +02:00
parent b5d699db21
commit c7338a1b7a

View File

@ -1975,6 +1975,15 @@ ContainerState::PopThebesLayerData()
if (userData->mForcedBackgroundColor != backgroundColor) {
// Invalidate the entire target ThebesLayer since we're changing
// the background color
#ifdef MOZ_DUMP_PAINTING
if (nsLayoutUtils::InvalidationDebuggingIsEnabled()) {
printf_stderr("Forced background color has changed from #%08X to #%08X on layer %p\n",
userData->mForcedBackgroundColor, backgroundColor, data->mLayer);
nsAutoCString str;
AppendToString(str, data->mLayer->GetValidRegion());
printf_stderr("Invalidating layer %p: %s\n", data->mLayer, str.get());
}
#endif
data->mLayer->InvalidateRegion(data->mLayer->GetValidRegion());
}
userData->mForcedBackgroundColor = backgroundColor;