public LayoutPartImageViewModel(LayoutPartImageProperties properties)
		{
			_imageBrush = null;
			_properties = properties ?? new LayoutPartImageProperties();
			_imagePage = new LayoutPartPropertyImagePageViewModel(this);
			UpdateLayoutPart();
		}
Example #2
0
		public ImagePartViewModel(LayoutPartImageProperties properties)
		{
			if (properties != null)
			{
				var brush = ImageHelper.GetResourceBrush(properties.ReferenceUID, properties.ImageType);
				if (brush != null)
					brush.Stretch = properties.Stretch.ToWindowsStretch();
				ImageBrush = brush;
			}
		}