fixed and cleaned up deactivate
still have error flash on ctrl-alt-R