Add action listeners and parsing to button handling code.

CoAuthors: rbkillea, lhnguyenduc