Solve crash on button touch. Fix some warning when not using Arc.