Fixed: counting of the number of events in selection for new measurement data structure. While at it optimized the said counting when closing selections.