simplified cancel button implementation