Change state of the panels when the are modified