SVS - fixes for windows build
SVS - merged refactoring branches