Adapt bottle object to use state_change().