Made previousState field protected.