1. Fixed bug with snapping after window moved away from edge. 2. Extra bloat and redundencies removed.