split common.js into events.js and util.js in preparation for event objects