restore replace and replace all buttons

#441