| | |
| | | using System.Runtime.CompilerServices; |
| | | using System.Windows; |
| | | using System.Windows.Controls; |
| | | using System.Windows.Controls.Primitives; |
| | | using System.Windows.Documents; |
| | | using System.Windows.Input; |
| | | using System.Windows.Media; |
| | | using System.Windows.Shapes; |
| | | using WPFProject.Models; |
| | | using WPFProject.UI.Test; |
| | | using WPFProject.Utils; |
| | | using static WPFProject.Utils.Resize.Resizeable; |
| | | |
| | | namespace WPFProject.Controls |
| | | { |
| | |
| | | |
| | | public DragType DragType { get; set; } = DragType.Canvas; |
| | | |
| | | private int _Zindex; |
| | | |
| | | public int Zindex |
| | | { |
| | | get { return _Zindex; } |
| | | set => RaiseAndSetIfChanged(ref _Zindex, value); |
| | | set |
| | | { |
| | | Canvas.SetZIndex(this, value); |
| | | } |
| | | } |
| | | |
| | | public AdornerDecorator ResizeAdornerDecorator { get => VisualTreeHelper.GetChild(this, 0) as AdornerDecorator; } |
| | | |
| | | |
| | | public event EventHandler MinEvent; |
| | |
| | | //throw new NotImplementedException(); |
| | | } |
| | | |
| | | private void InitThumb() |
| | | { |
| | | |
| | | } |
| | | |
| | | // 方形工厂 |
| | | FrameworkElementFactory GetFactory(Brush back) |
| | | { |
| | | FrameworkElementFactory fac = new FrameworkElementFactory(typeof(Rectangle)); |
| | | fac.SetValue(Rectangle.FillProperty, back); |
| | | return fac; |
| | | } |
| | | |
| | | private void InnerWindow_Loaded(object sender, RoutedEventArgs e) |
| | | { |
| | | if (canvasPosition == null) |