Added 'beforeHistoryChange" event.