Bug 786503: mark nsSMILInstanceTime::mVisited as mutable. r=birtles

This commit is contained in:
Daniel Holbert 2012-08-28 22:27:53 -07:00
parent 8b94e798f8
commit f462257c18
2 changed files with 3 additions and 4 deletions

View File

@ -167,9 +167,8 @@ nsSMILInstanceTime::IsDependentOn(const nsSMILInstanceTime& aOther) const
if (myBaseTime == &aOther)
return true;
// mVisited is mutable
mozilla::AutoRestore<bool> setVisited(const_cast<nsSMILInstanceTime*>(this)->mVisited);
const_cast<nsSMILInstanceTime*>(this)->mVisited = true;
mozilla::AutoRestore<bool> setVisited(mVisited);
mVisited = true;
return myBaseTime->IsDependentOn(aOther);
}

View File

@ -132,7 +132,7 @@ protected:
kWasDynamicEndpoint = 8
};
uint8_t mFlags; // Combination of kDynamic, kMayUpdate, etc.
bool mVisited; // (mutable) Cycle tracking
mutable bool mVisited; // Cycle tracking
// Additional reference count to determine if this instance time is currently
// used as a fixed endpoint in any intervals. Instance times that are used in