Changed Platform.NET minimum version to 4.0. Removed more legacy code