Splits code in EmsCommon#update

Splits update method into several smaller methods according to button
used.