setButtons functionality