Exemplo n.º 1
0
 /// <summary>
 /// Creates a new PortableTargetFramework instance for the given profile.
 /// </summary>
 public PortableTargetFramework(Profile profile)
 {
     this.targetFrameworkVersion = profile.TargetFrameworkVersion;
     this.targetFrameworkProfile = profile.TargetFrameworkProfile;
     this.displayName = profile.DisplayName;
     this.redistList = profile.ReferenceAssemblies;
 }
		public PortableTargetFramework(Profile profile)
			: base(profile.TargetFrameworkVersion + "-" + profile.TargetFrameworkProfile, profile.DisplayName)
		{
			this.TargetFrameworkVersion = profile.TargetFrameworkVersion;
			this.TargetFrameworkProfile = profile.TargetFrameworkProfile;
			this.MinimumMSBuildVersion = new Version(4, 0);
		}
		void UpdateSelectedProfile()
		{
			PropertyChanged(this, new PropertyChangedEventArgs("HasTwoOrMoreFrameworksSelected"));
			if (isSettingProfile)
				return;
			var requestedFrameworks = (from g in viewModels where g.IsChecked select g.SelectedVersion).ToList();
			var bestProfile = profileList.GetBestProfile(requestedFrameworks);
			if (bestProfile != selectedProfile) {
				selectedProfile = bestProfile;
				PropertyChanged(this, new PropertyChangedEventArgs("SelectedProfile"));
			}
		}