Пример #1
0
        public ImageData()
        {
            _openImageFileCommand = new Commands.OpenImageFileCommand(this);
            _zoomCommand          = new Commands.ZoomCommand(this);

            var  prop   = DesignerProperties.IsInDesignModeProperty;
            bool design = (bool)DependencyPropertyDescriptor.FromProperty(
                prop, typeof(FrameworkElement)).Metadata.DefaultValue;

            if (design)
            {
                ImagePath = Environment.GetFolderPath(
                    Environment.SpecialFolder.MyPictures)
                            + @"\Sample Pictures\Penguins.jpg";
            }
        }
Пример #2
0
 public ImageData()
 {
     _openImageFileCommand = new Commands.OpenImageFileCommand(this);
     _zoomCommand          = new Commands.ZoomCommand(this);
 }