Implements a switch function for Python.
Fix elevation slider state.