Moves recording button related code to toolbar.js.