fix bug which caused CycleThroughRegions to not work with empty regions;
handle edge case in NormalizeRegionEnds

Apparently, empty regions are falsy.
The edge case in NormalizeRegion ends occurs, when no selection is in the
viewport.