From 5f38782623d8247d912144b52cf505574976f885 Mon Sep 17 00:00:00 2001 From: liufei Date: Tue, 13 Apr 2021 15:26:19 +0800 Subject: [PATCH 01/29] 1.0beta --- App.xaml.cs | 8 +- Command/DelegateCommand.cs | 2 +- Constant/AppConstant.cs | 13 + Constant/DefaultConstant.cs | 8 +- Constant/SortType.cs | 8 +- DraggAnimatedPanel/DraggAnimatedPanel.Drag.cs | 326 ++-- DraggAnimatedPanel/DraggAnimatedPanel.cs | 403 ++-- GeekDesk.csproj | 6 +- MainWindow.xaml | 22 +- MainWindow.xaml.cs | 270 ++- Properties/AssemblyInfo.cs | 2 - Util/CommonCode.cs | 53 +- Util/ConsoleManager.cs | 4 - Util/DragAdorner.cs | 273 ++- Util/FileIcon.cs | 12 +- Util/ListViewDragDropManager.cs | 1692 ++++++++--------- Util/MenuWidthConvert.cs | 9 +- Util/MouseUtilities.cs | 88 +- Util/SystemIcon.cs | 7 - ViewModel/AppConfig.cs | 34 +- ViewModel/AppData.cs | 61 + ViewModel/DataInfos.cs | 70 - ViewModel/IconInfo.cs | 137 ++ ViewModel/MainModel.cs | 12 - ViewModel/MainViewModel.cs | 34 - ViewModel/MenuViewModel.cs | 11 +- 26 files changed, 1778 insertions(+), 1787 deletions(-) create mode 100644 Constant/AppConstant.cs create mode 100644 ViewModel/AppData.cs delete mode 100644 ViewModel/DataInfos.cs create mode 100644 ViewModel/IconInfo.cs delete mode 100644 ViewModel/MainModel.cs delete mode 100644 ViewModel/MainViewModel.cs diff --git a/App.xaml.cs b/App.xaml.cs index 26596fe..42e0140 100644 --- a/App.xaml.cs +++ b/App.xaml.cs @@ -1,10 +1,4 @@ -using System; -using System.Collections.Generic; -using System.Configuration; -using System.Data; -using System.Linq; -using System.Threading.Tasks; -using System.Windows; +using System.Windows; namespace GeekDesk { diff --git a/Command/DelegateCommand.cs b/Command/DelegateCommand.cs index be531b4..b7d7c37 100644 --- a/Command/DelegateCommand.cs +++ b/Command/DelegateCommand.cs @@ -50,7 +50,7 @@ namespace DraggAnimatedPanelExample /// Delegate to execute when CanExecute is called on the command. This can be null. /// When both and ar . public DelegateCommand(Action executeMethod, Func canExecuteMethod) - : base((o) => executeMethod((T) o), (o) => canExecuteMethod((T) o)) + : base((o) => executeMethod((T)o), (o) => canExecuteMethod((T)o)) { if (executeMethod == null || canExecuteMethod == null) throw new ArgumentNullException("executeMethod"); diff --git a/Constant/AppConstant.cs b/Constant/AppConstant.cs new file mode 100644 index 0000000..9d0d042 --- /dev/null +++ b/Constant/AppConstant.cs @@ -0,0 +1,13 @@ +using System; + +namespace GeekDesk.Constant +{ + class AppConstant + { + private static string APP_DIR = AppDomain.CurrentDomain.BaseDirectory.Trim(); + /// + /// app数据文件路径 + /// + public static string DATA_FILE_PATH = APP_DIR + "//Data"; //app数据文件路径 + } +} diff --git a/Constant/DefaultConstant.cs b/Constant/DefaultConstant.cs index a706f9b..33b95f7 100644 --- a/Constant/DefaultConstant.cs +++ b/Constant/DefaultConstant.cs @@ -1,10 +1,4 @@ -using System; -using System.Collections.Generic; -using System.Linq; -using System.Text; -using System.Threading.Tasks; - -/// +/// /// 默认参数 /// namespace GeekDesk.Constant diff --git a/Constant/SortType.cs b/Constant/SortType.cs index b2238e7..0255755 100644 --- a/Constant/SortType.cs +++ b/Constant/SortType.cs @@ -1,10 +1,4 @@ -using System; -using System.Collections.Generic; -using System.Linq; -using System.Text; -using System.Threading.Tasks; - -namespace GeekDesk.Constant +namespace GeekDesk.Constant { enum SortType { diff --git a/DraggAnimatedPanel/DraggAnimatedPanel.Drag.cs b/DraggAnimatedPanel/DraggAnimatedPanel.Drag.cs index 72877b9..006d10e 100644 --- a/DraggAnimatedPanel/DraggAnimatedPanel.Drag.cs +++ b/DraggAnimatedPanel/DraggAnimatedPanel.Drag.cs @@ -2,183 +2,181 @@ using System; using System.Windows; using System.Windows.Controls; -using System.Windows.Documents; using System.Windows.Input; using System.Windows.Media; -using System.Windows.Media.Animation; -using System.Windows.Navigation; namespace DraggAnimatedPanel { - /// - /// Description of SafariPanel_Drag. - /// - public partial class DraggAnimatedPanel - { - #region const drag - const double mouseDif = 2d; - const int mouseTimeDif = 25; - #endregion - - #region private - UIElement __draggedElement; - - public UIElement _draggedElement { - get { return __draggedElement; } - set - { - __draggedElement = value; - } - } - int _draggedIndex; - - bool _firstScrollRequest = true; - ScrollViewer _scrollContainer; - ScrollViewer scrollViewer - { - get - { - if (_firstScrollRequest && _scrollContainer == null) - { - _firstScrollRequest = false; - _scrollContainer = (ScrollViewer)GetParent(this as DependencyObject, (ve)=>ve is ScrollViewer); - } - return _scrollContainer; - } - } - #endregion - - #region private drag - double _lastMousePosX; - double _lastMousePosY; - int _lastMouseMoveTime; - double _x; - double _y; - Rect _rectOnDrag; - #endregion - - - void OnMouseMove(object sender,MouseEventArgs e) - { - if (e.LeftButton == MouseButtonState.Pressed && _draggedElement == null && !this.IsMouseCaptured) - StartDrag(e); - else if (_draggedElement != null) - OnDragOver(e); - } - - void OnDragOver(MouseEventArgs e) - { - Point mousePos = Mouse.GetPosition(this); - double difX = mousePos.X - _lastMousePosX; - double difY = mousePos.Y - _lastMousePosY; - - int timeDif = e.Timestamp - _lastMouseMoveTime; - if ((Math.Abs(difX) > mouseDif || Math.Abs(difY) > mouseDif) && timeDif > mouseTimeDif) - { - //this lines is for keepn draged item inside control bounds - DoScroll(); - - if (_x + difX < _rectOnDrag.Location.X) - _x = 0; - else if (ItemsWidth + _x + difX > _rectOnDrag.Location.X + _rectOnDrag.Width) - _x = _rectOnDrag.Location.X + _rectOnDrag.Width - ItemsWidth; - else if (mousePos.X > _rectOnDrag.Location.X && mousePos.X < _rectOnDrag.Location.X + _rectOnDrag.Width) - _x += difX; - if (_y + difY < _rectOnDrag.Location.Y) - _y = 0; - else if (ItemsHeight + _y + difY > _rectOnDrag.Location.Y + _rectOnDrag.Height) - _y = _rectOnDrag.Location.Y + _rectOnDrag.Height - ItemsHeight; - else if (mousePos.Y > _rectOnDrag.Location.Y && mousePos.Y < _rectOnDrag.Location.Y + _rectOnDrag.Height) - _y += difY; - //lines ends - - AnimateTo(_draggedElement,_x,_y, 0); - _lastMousePosX = mousePos.X; - _lastMousePosY = mousePos.Y; - _lastMouseMoveTime = e.Timestamp; - SwapElement(_x + ItemsWidth/2 , _y + ItemsHeight/2); - } - } - - void StartDrag(MouseEventArgs e) - { - Point mousePos = Mouse.GetPosition(this); - _draggedElement = GetChildThatHasMouseOver(); - if (_draggedElement == null) - return; - _draggedIndex = Children.IndexOf(_draggedElement); - _rectOnDrag = VisualTreeHelper.GetDescendantBounds(this); - Point p = GetItemVisualPoint(_draggedElement); - _x = p.X; - _y = p.Y; - SetZIndex(_draggedElement,1000); - _lastMousePosX = mousePos.X; - _lastMousePosY = mousePos.Y; - _lastMouseMoveTime = e.Timestamp; - this.InvalidateArrange(); - e.Handled = true; - this.CaptureMouse(); - } - - void OnMouseUp(object sender,MouseEventArgs e) - { - if (this.IsMouseCaptured) - ReleaseMouseCapture(); - } - - void SwapElement(double x, double y) - { - int index = GetIndexFromPoint(x,y); - if (index == _draggedIndex || index < 0) - return; - if (index >= Children.Count) - index = Children.Count - 1; - - int[] parameter = new int[]{_draggedIndex, index}; - if (SwapCommand != null && SwapCommand.CanExecute(parameter)) - { - SwapCommand.Execute(parameter); - _draggedElement = Children[index]; //this is bcause after changing the collection the element is other - FillNewDraggedChild(_draggedElement); - _draggedIndex = index; - } - - this.InvalidateArrange(); - } - - void FillNewDraggedChild(UIElement child) - { - if (child.RenderTransform as TransformGroup == null) + /// + /// Description of SafariPanel_Drag. + /// + public partial class DraggAnimatedPanel + { + #region const drag + const double mouseDif = 2d; + const int mouseTimeDif = 25; + #endregion + + #region private + UIElement __draggedElement; + + public UIElement _draggedElement + { + get { return __draggedElement; } + set + { + __draggedElement = value; + } + } + int _draggedIndex; + + bool _firstScrollRequest = true; + ScrollViewer _scrollContainer; + ScrollViewer scrollViewer + { + get + { + if (_firstScrollRequest && _scrollContainer == null) + { + _firstScrollRequest = false; + _scrollContainer = (ScrollViewer)GetParent(this as DependencyObject, (ve) => ve is ScrollViewer); + } + return _scrollContainer; + } + } + #endregion + + #region private drag + double _lastMousePosX; + double _lastMousePosY; + int _lastMouseMoveTime; + double _x; + double _y; + Rect _rectOnDrag; + #endregion + + + void OnMouseMove(object sender, MouseEventArgs e) + { + if (e.LeftButton == MouseButtonState.Pressed && _draggedElement == null && !this.IsMouseCaptured) + StartDrag(e); + else if (_draggedElement != null) + OnDragOver(e); + } + + void OnDragOver(MouseEventArgs e) + { + Point mousePos = Mouse.GetPosition(this); + double difX = mousePos.X - _lastMousePosX; + double difY = mousePos.Y - _lastMousePosY; + + int timeDif = e.Timestamp - _lastMouseMoveTime; + if ((Math.Abs(difX) > mouseDif || Math.Abs(difY) > mouseDif) && timeDif > mouseTimeDif) + { + //this lines is for keepn draged item inside control bounds + DoScroll(); + + if (_x + difX < _rectOnDrag.Location.X) + _x = 0; + else if (ItemsWidth + _x + difX > _rectOnDrag.Location.X + _rectOnDrag.Width) + _x = _rectOnDrag.Location.X + _rectOnDrag.Width - ItemsWidth; + else if (mousePos.X > _rectOnDrag.Location.X && mousePos.X < _rectOnDrag.Location.X + _rectOnDrag.Width) + _x += difX; + if (_y + difY < _rectOnDrag.Location.Y) + _y = 0; + else if (ItemsHeight + _y + difY > _rectOnDrag.Location.Y + _rectOnDrag.Height) + _y = _rectOnDrag.Location.Y + _rectOnDrag.Height - ItemsHeight; + else if (mousePos.Y > _rectOnDrag.Location.Y && mousePos.Y < _rectOnDrag.Location.Y + _rectOnDrag.Height) + _y += difY; + //lines ends + + AnimateTo(_draggedElement, _x, _y, 0); + _lastMousePosX = mousePos.X; + _lastMousePosY = mousePos.Y; + _lastMouseMoveTime = e.Timestamp; + SwapElement(_x + ItemsWidth / 2, _y + ItemsHeight / 2); + } + } + + void StartDrag(MouseEventArgs e) + { + Point mousePos = Mouse.GetPosition(this); + _draggedElement = GetChildThatHasMouseOver(); + if (_draggedElement == null) + return; + _draggedIndex = Children.IndexOf(_draggedElement); + _rectOnDrag = VisualTreeHelper.GetDescendantBounds(this); + Point p = GetItemVisualPoint(_draggedElement); + _x = p.X; + _y = p.Y; + SetZIndex(_draggedElement, 1000); + _lastMousePosX = mousePos.X; + _lastMousePosY = mousePos.Y; + _lastMouseMoveTime = e.Timestamp; + this.InvalidateArrange(); + e.Handled = true; + this.CaptureMouse(); + } + + void OnMouseUp(object sender, MouseEventArgs e) + { + if (this.IsMouseCaptured) + ReleaseMouseCapture(); + } + + void SwapElement(double x, double y) + { + int index = GetIndexFromPoint(x, y); + if (index == _draggedIndex || index < 0) + return; + if (index >= Children.Count) + index = Children.Count - 1; + + int[] parameter = new int[] { _draggedIndex, index }; + if (SwapCommand != null && SwapCommand.CanExecute(parameter)) + { + SwapCommand.Execute(parameter); + _draggedElement = Children[index]; //this is bcause after changing the collection the element is other + FillNewDraggedChild(_draggedElement); + _draggedIndex = index; + } + + this.InvalidateArrange(); + } + + void FillNewDraggedChild(UIElement child) + { + if (child.RenderTransform as TransformGroup == null) { child.RenderTransformOrigin = new Point(0.5, 0.5); TransformGroup group = new TransformGroup(); child.RenderTransform = group; group.Children.Add(new TranslateTransform()); } - SetZIndex(child,1000); - AnimateTo(child,_x,_y, 0); //need relocate the element - } - - void OnLostMouseCapture(object sender,MouseEventArgs e) - { - FinishDrag(); - } - - void FinishDrag() - { - if (_draggedElement != null) - { - SetZIndex(_draggedElement,0); - _draggedElement = null; - this.InvalidateArrange(); - } - } - - void DoScroll() + SetZIndex(child, 1000); + AnimateTo(child, _x, _y, 0); //need relocate the element + } + + void OnLostMouseCapture(object sender, MouseEventArgs e) + { + FinishDrag(); + } + + void FinishDrag() + { + if (_draggedElement != null) + { + SetZIndex(_draggedElement, 0); + _draggedElement = null; + this.InvalidateArrange(); + } + } + + void DoScroll() { if (scrollViewer != null) { - Point position = Mouse.GetPosition(scrollViewer); + Point position = Mouse.GetPosition(scrollViewer); double scrollMargin = Math.Min(scrollViewer.FontSize * 2, scrollViewer.ActualHeight / 2); if (position.X >= scrollViewer.ActualWidth - scrollMargin && @@ -201,5 +199,5 @@ namespace DraggAnimatedPanel } } } - } + } } diff --git a/DraggAnimatedPanel/DraggAnimatedPanel.cs b/DraggAnimatedPanel/DraggAnimatedPanel.cs index 81bd82d..53ad471 100644 --- a/DraggAnimatedPanel/DraggAnimatedPanel.cs +++ b/DraggAnimatedPanel/DraggAnimatedPanel.cs @@ -1,237 +1,234 @@ /*Developed by (doiTTeam)=>doiTTeam.mail = devdoiTTeam@gmail.com*/ using System; using System.Linq; -using System.Runtime.CompilerServices; using System.Windows; using System.Windows.Controls; -using System.Windows.Documents; using System.Windows.Input; using System.Windows.Media; using System.Windows.Media.Animation; -using System.Windows.Navigation; namespace DraggAnimatedPanel { - /// - /// Description of DraggAnimatedPanel. - /// - public partial class DraggAnimatedPanel : WrapPanel - { - #region private vars - Size _calculatedSize; - bool _isNotFirstArrange = false; - int columns, rows; - #endregion - static DraggAnimatedPanel() - { - DefaultStyleKeyProperty.OverrideMetadata(typeof(DraggAnimatedPanel), new FrameworkPropertyMetadata(typeof(DraggAnimatedPanel))); - } + /// + /// Description of DraggAnimatedPanel. + /// + public partial class DraggAnimatedPanel : WrapPanel + { + #region private vars + Size _calculatedSize; + bool _isNotFirstArrange = false; + int columns, rows; + #endregion + static DraggAnimatedPanel() + { + DefaultStyleKeyProperty.OverrideMetadata(typeof(DraggAnimatedPanel), new FrameworkPropertyMetadata(typeof(DraggAnimatedPanel))); + } - public DraggAnimatedPanel() : base() - { - this.AddHandler(Mouse.MouseMoveEvent, new MouseEventHandler(OnMouseMove), false); - this.MouseLeftButtonUp += OnMouseUp; - this.LostMouseCapture += OnLostMouseCapture; - } + public DraggAnimatedPanel() : base() + { + this.AddHandler(Mouse.MouseMoveEvent, new MouseEventHandler(OnMouseMove), false); + this.MouseLeftButtonUp += OnMouseUp; + this.LostMouseCapture += OnLostMouseCapture; + } - UIElement GetChildThatHasMouseOver() - { - return GetParent(Mouse.DirectlyOver as DependencyObject, (ve) => Children.Contains(ve as UIElement)) as UIElement; - } + UIElement GetChildThatHasMouseOver() + { + return GetParent(Mouse.DirectlyOver as DependencyObject, (ve) => Children.Contains(ve as UIElement)) as UIElement; + } - Point GetItemVisualPoint(UIElement element) - { - TransformGroup group = (TransformGroup)element.RenderTransform; - TranslateTransform trans = (TranslateTransform)group.Children[0]; + Point GetItemVisualPoint(UIElement element) + { + TransformGroup group = (TransformGroup)element.RenderTransform; + TranslateTransform trans = (TranslateTransform)group.Children[0]; - return new Point(trans.X, trans.Y); - } + return new Point(trans.X, trans.Y); + } - int GetIndexFromPoint(double x, double y) - { - int columnIndex = (int)Math.Truncate(x / itemContainterWidth); - int rowIndex = (int)Math.Truncate(y / itemContainterHeight); - return columns * rowIndex + columnIndex; - } - int GetIndexFromPoint(Point p) - { - return GetIndexFromPoint(p.X, p.Y); - } + int GetIndexFromPoint(double x, double y) + { + int columnIndex = (int)Math.Truncate(x / itemContainterWidth); + int rowIndex = (int)Math.Truncate(y / itemContainterHeight); + return columns * rowIndex + columnIndex; + } + int GetIndexFromPoint(Point p) + { + return GetIndexFromPoint(p.X, p.Y); + } - #region dependency properties - public static readonly DependencyProperty ItemsWidthProperty = - DependencyProperty.Register( - "ItemsWidth", - typeof(double), - typeof(DraggAnimatedPanel), - new FrameworkPropertyMetadata(150d)); + #region dependency properties + public static readonly DependencyProperty ItemsWidthProperty = + DependencyProperty.Register( + "ItemsWidth", + typeof(double), + typeof(DraggAnimatedPanel), + new FrameworkPropertyMetadata(150d)); - public static readonly DependencyProperty ItemsHeightProperty = - DependencyProperty.Register( - "ItemsHeight", - typeof(double), - typeof(DraggAnimatedPanel), - new FrameworkPropertyMetadata(60d)); + public static readonly DependencyProperty ItemsHeightProperty = + DependencyProperty.Register( + "ItemsHeight", + typeof(double), + typeof(DraggAnimatedPanel), + new FrameworkPropertyMetadata(60d)); - public static readonly DependencyProperty ItemSeparationProperty = - DependencyProperty.Register( - "ItemSeparation", - typeof(Thickness), - typeof(DraggAnimatedPanel), - new FrameworkPropertyMetadata()); + public static readonly DependencyProperty ItemSeparationProperty = + DependencyProperty.Register( + "ItemSeparation", + typeof(Thickness), + typeof(DraggAnimatedPanel), + new FrameworkPropertyMetadata()); - // Using a DependencyProperty as the backing store for AnimationMilliseconds. This enables animation, styling, binding, etc... - public static readonly DependencyProperty AnimationMillisecondsProperty = - DependencyProperty.Register("AnimationMilliseconds", typeof(int), typeof(DraggAnimatedPanel), new FrameworkPropertyMetadata(200)); + // Using a DependencyProperty as the backing store for AnimationMilliseconds. This enables animation, styling, binding, etc... + public static readonly DependencyProperty AnimationMillisecondsProperty = + DependencyProperty.Register("AnimationMilliseconds", typeof(int), typeof(DraggAnimatedPanel), new FrameworkPropertyMetadata(200)); - public static readonly DependencyProperty SwapCommandProperty = - DependencyProperty.Register( - "SwapCommand", - typeof(ICommand), - typeof(DraggAnimatedPanel), - new FrameworkPropertyMetadata(null)); + public static readonly DependencyProperty SwapCommandProperty = + DependencyProperty.Register( + "SwapCommand", + typeof(ICommand), + typeof(DraggAnimatedPanel), + new FrameworkPropertyMetadata(null)); - #endregion + #endregion - #region properties - public double ItemsWidth - { - get { return (double)GetValue(ItemsWidthProperty); } - set { SetValue(ItemsWidthProperty, value); } - } - public double ItemsHeight - { - get { return (double)GetValue(ItemsHeightProperty); } - set { SetValue(ItemsHeightProperty, value); } - } - public Thickness ItemSeparation - { - get { return (Thickness)this.GetValue(ItemSeparationProperty); } - set { this.SetValue(ItemSeparationProperty, value); } - } - public int AnimationMilliseconds - { - get { return (int)GetValue(AnimationMillisecondsProperty); } - set { SetValue(AnimationMillisecondsProperty, value); } - } - private double itemContainterHeight - { - get { return ItemSeparation.Top + ItemsHeight + ItemSeparation.Bottom; } - } - private double itemContainterWidth - { - get { return ItemSeparation.Left + ItemsWidth + ItemSeparation.Right; } - } - public ICommand SwapCommand - { - get { return (ICommand)GetValue(SwapCommandProperty); } - set { SetValue(SwapCommandProperty, value); } - } - #endregion + #region properties + public double ItemsWidth + { + get { return (double)GetValue(ItemsWidthProperty); } + set { SetValue(ItemsWidthProperty, value); } + } + public double ItemsHeight + { + get { return (double)GetValue(ItemsHeightProperty); } + set { SetValue(ItemsHeightProperty, value); } + } + public Thickness ItemSeparation + { + get { return (Thickness)this.GetValue(ItemSeparationProperty); } + set { this.SetValue(ItemSeparationProperty, value); } + } + public int AnimationMilliseconds + { + get { return (int)GetValue(AnimationMillisecondsProperty); } + set { SetValue(AnimationMillisecondsProperty, value); } + } + private double itemContainterHeight + { + get { return ItemSeparation.Top + ItemsHeight + ItemSeparation.Bottom; } + } + private double itemContainterWidth + { + get { return ItemSeparation.Left + ItemsWidth + ItemSeparation.Right; } + } + public ICommand SwapCommand + { + get { return (ICommand)GetValue(SwapCommandProperty); } + set { SetValue(SwapCommandProperty, value); } + } + #endregion - #region transformation things - private void AnimateAll() - { - //Apply exactly the same algorithm, but instide of Arrange a call AnimateTo method - double colPosition = 0; - double rowPosition = 0; - foreach (UIElement child in Children) - { - if (child != _draggedElement) - AnimateTo(child, colPosition + ItemSeparation.Left, rowPosition + ItemSeparation.Top, _isNotFirstArrange ? AnimationMilliseconds : 0); - //drag will locate dragged element - colPosition += itemContainterWidth; - if (colPosition + 1 > _calculatedSize.Width) - { - colPosition = 0; - rowPosition += itemContainterHeight; - } - } - } + #region transformation things + private void AnimateAll() + { + //Apply exactly the same algorithm, but instide of Arrange a call AnimateTo method + double colPosition = 0; + double rowPosition = 0; + foreach (UIElement child in Children) + { + if (child != _draggedElement) + AnimateTo(child, colPosition + ItemSeparation.Left, rowPosition + ItemSeparation.Top, _isNotFirstArrange ? AnimationMilliseconds : 0); + //drag will locate dragged element + colPosition += itemContainterWidth; + if (colPosition + 1 > _calculatedSize.Width) + { + colPosition = 0; + rowPosition += itemContainterHeight; + } + } + } - private void AnimateTo(UIElement child, double x, double y, int duration) - { - TransformGroup group = (TransformGroup)child.RenderTransform; - TranslateTransform trans = (TranslateTransform)group.Children.First((groupElement) => groupElement is TranslateTransform); + private void AnimateTo(UIElement child, double x, double y, int duration) + { + TransformGroup group = (TransformGroup)child.RenderTransform; + TranslateTransform trans = (TranslateTransform)group.Children.First((groupElement) => groupElement is TranslateTransform); - trans.BeginAnimation(TranslateTransform.XProperty, MakeAnimation(x, duration)); - trans.BeginAnimation(TranslateTransform.YProperty, MakeAnimation(y, duration)); - } + trans.BeginAnimation(TranslateTransform.XProperty, MakeAnimation(x, duration)); + trans.BeginAnimation(TranslateTransform.YProperty, MakeAnimation(y, duration)); + } - private DoubleAnimation MakeAnimation(double to, int duration) - { - DoubleAnimation anim = new DoubleAnimation(to, TimeSpan.FromMilliseconds(duration)); - anim.AccelerationRatio = 0.2; - anim.DecelerationRatio = 0.7; - return anim; - } - #endregion + private DoubleAnimation MakeAnimation(double to, int duration) + { + DoubleAnimation anim = new DoubleAnimation(to, TimeSpan.FromMilliseconds(duration)); + anim.AccelerationRatio = 0.2; + anim.DecelerationRatio = 0.7; + return anim; + } + #endregion - #region measure - protected override Size MeasureOverride(Size availableSize) - { - Size itemContainerSize = new Size(itemContainterWidth, itemContainterHeight); - int count = 0; //for not call it again - foreach (UIElement child in Children) - { - child.Measure(itemContainerSize); - count++; - } - if (availableSize.Width < itemContainterWidth) - _calculatedSize = new Size(itemContainterWidth, count * itemContainterHeight); //the size of nX1 - else - { - columns = (int)Math.Truncate(availableSize.Width / itemContainterWidth); - rows = count / columns; - if (count % columns != 0) - rows++; - _calculatedSize = new Size(columns * itemContainterWidth, rows * itemContainterHeight); - } - return _calculatedSize; - } - #endregion + #region measure + protected override Size MeasureOverride(Size availableSize) + { + Size itemContainerSize = new Size(itemContainterWidth, itemContainterHeight); + int count = 0; //for not call it again + foreach (UIElement child in Children) + { + child.Measure(itemContainerSize); + count++; + } + if (availableSize.Width < itemContainterWidth) + _calculatedSize = new Size(itemContainterWidth, count * itemContainterHeight); //the size of nX1 + else + { + columns = (int)Math.Truncate(availableSize.Width / itemContainterWidth); + rows = count / columns; + if (count % columns != 0) + rows++; + _calculatedSize = new Size(columns * itemContainterWidth, rows * itemContainterHeight); + } + return _calculatedSize; + } + #endregion - #region arrange - protected override Size ArrangeOverride(Size finalSize) - { - Size _finalItemSize = new Size(ItemsWidth, ItemsHeight); - //if is animated then arrange elements to 0,0, and then put them on its location using the transform - foreach (UIElement child in InternalChildren) - { - // If this is the first time we've seen this child, add our transforms - if (child.RenderTransform as TransformGroup == null) - { - child.RenderTransformOrigin = new Point(0.5, 0.5); - TransformGroup group = new TransformGroup(); - child.RenderTransform = group; - group.Children.Add(new TranslateTransform()); - } - //locate all children in 0,0 point//TODO: use infinity and then scale each element to items size - child.Arrange(new Rect(new Point(0, 0), _finalItemSize)); //when use transformations change to childs.DesireSize - } - AnimateAll(); + #region arrange + protected override Size ArrangeOverride(Size finalSize) + { + Size _finalItemSize = new Size(ItemsWidth, ItemsHeight); + //if is animated then arrange elements to 0,0, and then put them on its location using the transform + foreach (UIElement child in InternalChildren) + { + // If this is the first time we've seen this child, add our transforms + if (child.RenderTransform as TransformGroup == null) + { + child.RenderTransformOrigin = new Point(0.5, 0.5); + TransformGroup group = new TransformGroup(); + child.RenderTransform = group; + group.Children.Add(new TranslateTransform()); + } + //locate all children in 0,0 point//TODO: use infinity and then scale each element to items size + child.Arrange(new Rect(new Point(0, 0), _finalItemSize)); //when use transformations change to childs.DesireSize + } + AnimateAll(); - if (!_isNotFirstArrange) - _isNotFirstArrange = true; + if (!_isNotFirstArrange) + _isNotFirstArrange = true; - return _calculatedSize; - } - #endregion + return _calculatedSize; + } + #endregion - #region Static - //this can be an extension method - public static DependencyObject GetParent(DependencyObject o, Func matchFunction) - { - DependencyObject t = o; - do - { - t = VisualTreeHelper.GetParent(t); - } while (t != null && !matchFunction.Invoke(t)); - return t; - } - #endregion + #region Static + //this can be an extension method + public static DependencyObject GetParent(DependencyObject o, Func matchFunction) + { + DependencyObject t = o; + do + { + t = VisualTreeHelper.GetParent(t); + } while (t != null && !matchFunction.Invoke(t)); + return t; + } + #endregion - //TODO: Add IsEditing property - //TODO: Add Scale transform to items for fill items area - } + //TODO: Add IsEditing property + //TODO: Add Scale transform to items for fill items area + } } diff --git a/GeekDesk.csproj b/GeekDesk.csproj index 70cf898..bb1fb78 100644 --- a/GeekDesk.csproj +++ b/GeekDesk.csproj @@ -85,6 +85,7 @@ + @@ -98,9 +99,8 @@ - - - + + MSBuild:Compile diff --git a/MainWindow.xaml b/MainWindow.xaml index cae0118..d4b3e84 100644 --- a/MainWindow.xaml +++ b/MainWindow.xaml @@ -8,7 +8,7 @@ xmlns:util="clr-namespace:GeekDesk.Util" xmlns:DraggAnimatedPanel="clr-namespace:DraggAnimatedPanel" x:Name="window" xmlns:hc="https://handyorg.github.io/handycontrol" - Title="MainWindow" Height="450" Width="800"> + Title="MainWindow" Height="500" Width="600"> + + + + + + + + @@ -127,28 +144,18 @@ Effect="{DynamicResource EffectShadow2}" Margin="5,5,0,5" > - - + - - - + + + @@ -165,7 +172,24 @@ - + + + + @@ -189,7 +213,6 @@ - - + + - - + + diff --git a/MainWindow.xaml.cs b/MainWindow.xaml.cs index 5c26a07..cd0c275 100644 --- a/MainWindow.xaml.cs +++ b/MainWindow.xaml.cs @@ -1,9 +1,11 @@ using DraggAnimatedPanelExample; -using GalaSoft.MvvmLight; using GeekDesk.Util; using GeekDesk.ViewModel; using System; +using System.Collections; using System.Collections.Generic; +using System.Collections.ObjectModel; +using System.ComponentModel; using System.IO; using System.Windows; using System.Windows.Controls; @@ -19,7 +21,8 @@ namespace GeekDesk public partial class MainWindow : Window { - private static AppData appData = CommonCode.GetAppData(); + private AppData appData = CommonCode.GetAppDataByFile(); + private int menuSelectIndexTemp = -1; public MainWindow() { InitializeComponent(); @@ -40,19 +43,20 @@ namespace GeekDesk private void loadData() { this.DataContext = appData; - appData.MenuList.Add("Test1"); + //menus.ItemsSource = appData.MenuList; + appData.MenuList.Add(new MenuInfo() { MenuName = "test1", MenuId = "1", MenuEdit = (int)Visibility.Collapsed }); this.Width = appData.AppConfig.WindowWidth; this.Height = appData.AppConfig.WindowHeight; - List iconList; + ObservableCollection iconList; if (appData.IconMap.ContainsKey("1")) { iconList = appData.IconMap["1"]; } else { - iconList = new List(); + iconList = new ObservableCollection(); appData.IconMap.Add("1", iconList); } icons.ItemsSource = iconList; @@ -89,6 +93,8 @@ namespace GeekDesk } } DelegateCommand _swap2; + + public DelegateCommand SwapCommand2 { get @@ -99,18 +105,22 @@ namespace GeekDesk { int fromS = indexes[0]; int to = indexes[1]; - var elementSource = menus.Items[to]; - var dragged = menus.Items[fromS]; + ObservableCollection menuList = appData.MenuList; + var elementSource = menuList[to]; + var dragged = menuList[fromS]; if (fromS > to) { - menus.Items.Remove(dragged); - menus.Items.Insert(to, dragged); + menuList.Remove(dragged); + menuList.Insert(to, dragged); } else { - menus.Items.Remove(dragged); - menus.Items.Insert(to, dragged); + menuList.Remove(dragged); + menuList.Insert(to, dragged); } + appData.MenuList = menuList; + //menus.Items.Refresh(); + } ); return _swap2; @@ -134,14 +144,14 @@ namespace GeekDesk iconInfo.Path = path; iconInfo.BitmapImage = bi; iconInfo.Name = Path.GetFileNameWithoutExtension(path); - List iconList; + ObservableCollection iconList; if (appData.IconMap.ContainsKey("1")) { iconList = appData.IconMap["1"]; } else { - iconList = new List(); + iconList = new ObservableCollection(); appData.IconMap.Add("1", iconList); } iconList.Add(iconInfo); @@ -231,44 +241,119 @@ namespace GeekDesk } - private void deleteMenu(object sender, RoutedEventArgs e) + /// + /// 删除菜单 + /// + /// + /// + private void DeleteMenu(object sender, RoutedEventArgs e) { - //if (data.SelectedIndex == -1) - //{ - // return; - //} - ViewModel.Menu pojo = (ViewModel.Menu)((ContextMenu)((MenuItem)sender).Parent).DataContext; - string menuTitle = pojo.menu; - int index = 0; - foreach (object obj in menus.Items) - { - string test = ((ViewModel.Menu)obj).menu; - if (test == menuTitle) - { - menus.Items.RemoveAt(index); - menus.Items.Refresh(); - return; - } - index++; - } - + MenuInfo menuInfo = ((MenuItem)sender).Tag as MenuInfo; + appData.MenuList.Remove(menuInfo); + CommonCode.SaveAppData(appData); } + private void StackPanel_MouseMove(object sender, MouseEventArgs e) + { + UIElementCollection childs = ((StackPanel)sender).Children; + IEnumerator iEnumerator = childs.GetEnumerator(); + //((Image)iEnumerator.Current).Style; + } + /// + /// 重命名菜单 将textbox 设置为可见 + /// + /// + /// + private void RenameMenu(object sender, RoutedEventArgs e) + { + MenuInfo menuInfo = ((MenuItem)sender).Tag as MenuInfo; + menuInfo.MenuEdit = (int)Visibility.Visible; + + } + /// + /// 编辑菜单失焦或者敲下Enter键时保存修改后的菜单 + /// + /// + /// + private void LostFocusOrEnterDown(object sender, EventArgs e) + { + TextBox menuBox = null; + if (e.GetType() == typeof(KeyEventArgs)) + { + KeyEventArgs eKey = e as KeyEventArgs; + if (eKey.Key == Key.Enter) + { + menuBox = ((TextBox)sender); + } + } else if(e.GetType() == typeof(RoutedEventArgs)) + { + menuBox = ((TextBox)sender); + } + + if (menuBox != null) + { + MenuInfo menuInfo = menuBox.Tag as MenuInfo; + string text = menuBox.Text; + menuInfo.MenuName = text; + menuInfo.MenuEdit = (int)Visibility.Collapsed; + CommonCode.SaveAppData(appData); + } + } + + /// + /// 当修改菜单元素可见时 设置全选并获得焦点 + /// + /// + /// + private void MenuEditWhenVisibilityChanged(object sender, DependencyPropertyChangedEventArgs e) + { + TextBox box = sender as TextBox; + if (box.Visibility == Visibility.Visible) + { + Keyboard.Focus(box); + box.SelectAll(); + } + } + + /// + /// 当修改菜单元素可见时 设置原菜单为不可见 并且不可选中 + /// 修改菜单元素不可见时 原菜单可见 并 选中 + /// + /// + /// + private void MenuWhenVisibilityChanged(object sender, DependencyPropertyChangedEventArgs e) + { + TextBlock tb = sender as TextBlock; + if (tb.Visibility == Visibility.Collapsed) + { + if (menus.SelectedIndex != -1) + { + menuSelectIndexTemp = menus.SelectedIndex; + menus.SelectedIndex = -1; + } else + { + menus.SelectedIndex = menuSelectIndexTemp; + } + } + } + + /// + /// 新建菜单 + /// + /// + /// + private void CreateMenu(object sender, RoutedEventArgs e) + { + appData.MenuList.Add(new MenuInfo() { MenuEdit = (int)Visibility.Collapsed, MenuId = "zz", MenuName = "NewGouop" }); + menus.SelectedIndex = appData.MenuList.Count - 1; + //appData.MenuList[appData.MenuList.Count - 1].MenuEdit = (int)Visibility.Visible; + CommonCode.SaveAppData(appData); + } } - public class MainModel : ViewModelBase - { - public List MenuList { get; set; } - - public List DataList { get; set; } - - - } - - } diff --git a/Util/CommonCode.cs b/Util/CommonCode.cs index b71d881..5da8c9d 100644 --- a/Util/CommonCode.cs +++ b/Util/CommonCode.cs @@ -15,7 +15,7 @@ namespace GeekDesk.Util /// 获取app 数据 /// /// - public static AppData GetAppData() + public static AppData GetAppDataByFile() { AppData appData; if (!File.Exists(AppConstant.DATA_FILE_PATH)) diff --git a/Util/VisibilityConvert.cs b/Util/VisibilityConvert.cs new file mode 100644 index 0000000..0c5fe2d --- /dev/null +++ b/Util/VisibilityConvert.cs @@ -0,0 +1,33 @@ +using System; +using System.Collections.Generic; +using System.Globalization; +using System.Linq; +using System.Text; +using System.Threading.Tasks; +using System.Windows; +using System.Windows.Data; + +namespace GeekDesk.Util +{ + class VisibilityConvert : IValueConverter + { + public object Convert(object value, Type targetType, object parameter, CultureInfo culture) + { + int v = (int)value; + + if (v == (int)Visibility.Visible) + { + return Visibility.Visible; + } else if (v == (int)Visibility.Collapsed) + { + return Visibility.Collapsed; + } + return v; + } + + public object ConvertBack(object value, Type targetType, object parameter, CultureInfo culture) + { + throw new NotImplementedException(); + } + } +} diff --git a/ViewModel/AppData.cs b/ViewModel/AppData.cs index 4229674..f9d14b4 100644 --- a/ViewModel/AppData.cs +++ b/ViewModel/AppData.cs @@ -1,5 +1,6 @@ using System; using System.Collections.Generic; +using System.Collections.ObjectModel; using System.ComponentModel; namespace GeekDesk.ViewModel @@ -7,11 +8,11 @@ namespace GeekDesk.ViewModel [Serializable] class AppData : INotifyPropertyChanged { - private List menuList = new List(); - private Dictionary> iconMap = new Dictionary>(); + private ObservableCollection menuList = new ObservableCollection(); + private Dictionary> iconMap = new Dictionary>(); private AppConfig appConfig = new AppConfig(); - public List MenuList + public ObservableCollection MenuList { get { @@ -24,7 +25,7 @@ namespace GeekDesk.ViewModel } } - public Dictionary> IconMap + public Dictionary> IconMap { get { diff --git a/ViewModel/IconInfo.cs b/ViewModel/IconInfo.cs index d685f0d..6341a53 100644 --- a/ViewModel/IconInfo.cs +++ b/ViewModel/IconInfo.cs @@ -1,4 +1,5 @@ -using System; +using GeekDesk.Constant; +using System; using System.ComponentModel; using System.IO; using System.Windows.Media.Imaging; @@ -15,6 +16,8 @@ namespace GeekDesk.ViewModel private BitmapImage bitmapImage; //位图 private byte[] imageByteArr; //图片 base64 private string content; //显示信息 + private int imageWidth = (int)DefaultConstant.IMAGE_WIDTH; + private int imageHeight = (int)DefaultConstant.IMAGE_HEIGHT; public int Count { @@ -100,6 +103,19 @@ namespace GeekDesk.ViewModel } } + public int ImageWidth + { + get + { + return imageWidth; + } + set + { + imageWidth = value; + OnPropertyChanged("ImageWidth"); + } + } + [field: NonSerializedAttribute()] diff --git a/ViewModel/MenuInfo.cs b/ViewModel/MenuInfo.cs new file mode 100644 index 0000000..8564f30 --- /dev/null +++ b/ViewModel/MenuInfo.cs @@ -0,0 +1,86 @@ +using System; +using System.Collections.Generic; +using System.ComponentModel; +using System.Linq; +using System.Text; +using System.Threading.Tasks; +using System.Windows; + +namespace GeekDesk.ViewModel +{ + + [Serializable] + class MenuInfo : INotifyPropertyChanged + { + [field: NonSerializedAttribute()] + public event PropertyChangedEventHandler PropertyChanged; + private void OnPropertyChanged(string propertyName) + { + PropertyChanged?.Invoke(this, new PropertyChangedEventArgs(propertyName)); + } + + private string menuName; + private string menuId; + private int menuEdit = (int)Visibility.Collapsed; + private int notMenuEdit = (int)Visibility.Visible; + + public string MenuName + { + get + { + return menuName; + } + set + { + menuName = value; + OnPropertyChanged("MenuName"); + } + } + + public string MenuId + { + get + { + return menuId; + } + set + { + menuId = value; + OnPropertyChanged("MenuId"); + } + } + + public int MenuEdit + { + get + { + return menuEdit; + } + set + { + menuEdit = value; + if (menuEdit == (int)Visibility.Visible) + { + NotMenuEdit = (int)Visibility.Collapsed; + } else + { + NotMenuEdit = (int)Visibility.Visible; + } + OnPropertyChanged("MenuEdit"); + } + } + + public int NotMenuEdit + { + get + { + return notMenuEdit; + } + set + { + notMenuEdit = value; + OnPropertyChanged("NotMenuEdit"); + } + } + } +} diff --git a/ViewModel/MenuViewModel.cs b/ViewModel/MenuViewModel.cs deleted file mode 100644 index 652a67c..0000000 --- a/ViewModel/MenuViewModel.cs +++ /dev/null @@ -1,31 +0,0 @@ -using System.Collections.ObjectModel; - -namespace GeekDesk.ViewModel -{ - class MenuViewModel - { - - public MenuViewModel() - { - - } - - public ObservableCollection GetMenus() - { - ObservableCollection menus = new ObservableCollection(); - menus.Add(new Menu() { menu = "test1" }); - menus.Add(new Menu() { menu = "test2" }); - menus.Add(new Menu() { menu = "test3" }); - return menus; - } - - - } - - - - public class Menu - { - public string menu { get; set; } - } -} From ef7cb465a113f1c594cba7b919facd7dc94b8c9a Mon Sep 17 00:00:00 2001 From: liufei Date: Wed, 12 May 2021 10:00:12 +0800 Subject: [PATCH 03/29] =?UTF-8?q?=E6=9A=82=E6=97=B6=E5=8F=AF=E7=AE=80?= =?UTF-8?q?=E5=8D=95=E4=BD=BF=E7=94=A8?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- App.xaml | 1 + GeekDesk.csproj | 31 ++- MainWindow.xaml | 197 +++++++++--------- MainWindow.xaml.cs | 134 ++++++------- Resource/DefaultIconfont/iconfont.json | 219 +++++++++++++++++++++ Resource/DefaultIconfont/iconfont.svg | 116 +++++++++++ Resource/DefaultIconfont/iconfont.ttf | Bin 0 -> 12332 bytes Resource/Dictionary/GemetryDictionary.xaml | 11 ++ Resource/Image/Ico.ico | Bin 0 -> 233534 bytes Resource/Image/Ico.png | Bin 0 -> 5062 bytes Resource/Image/WindowLogo.png | Bin 0 -> 8211 bytes Util/HotKey.cs | 89 +++++++++ ViewModel/AppConfig.cs | 14 ++ ViewModel/AppData.cs | 13 -- ViewModel/IconInfo.cs | 15 ++ ViewModel/MenuInfo.cs | 29 ++- packages.config | 5 +- 17 files changed, 672 insertions(+), 202 deletions(-) create mode 100644 Resource/DefaultIconfont/iconfont.json create mode 100644 Resource/DefaultIconfont/iconfont.svg create mode 100644 Resource/DefaultIconfont/iconfont.ttf create mode 100644 Resource/Dictionary/GemetryDictionary.xaml create mode 100644 Resource/Image/Ico.ico create mode 100644 Resource/Image/Ico.png create mode 100644 Resource/Image/WindowLogo.png create mode 100644 Util/HotKey.cs diff --git a/App.xaml b/App.xaml index 53e826a..e7f6a79 100644 --- a/App.xaml +++ b/App.xaml @@ -11,6 +11,7 @@ + diff --git a/GeekDesk.csproj b/GeekDesk.csproj index 608ad9d..9a5f64b 100644 --- a/GeekDesk.csproj +++ b/GeekDesk.csproj @@ -41,29 +41,14 @@ packages\CommonServiceLocator.2.0.6\lib\net45\CommonServiceLocator.dll - - packages\MvvmLightLibs.5.4.1.1\lib\net45\GalaSoft.MvvmLight.dll - - - packages\MvvmLightLibs.5.4.1.1\lib\net45\GalaSoft.MvvmLight.Extras.dll - - - packages\MvvmLightLibs.5.4.1.1\lib\net45\GalaSoft.MvvmLight.Platform.dll - packages\HandyControl.3.1.0\lib\net452\HandyControl.dll - - packages\Newtonsoft.Json.13.0.1\lib\net45\Newtonsoft.Json.dll - - packages\System.Drawing.Common.5.0.2\lib\net461\System.Drawing.Common.dll - - - packages\MvvmLightLibs.5.4.1.1\lib\net45\System.Windows.Interactivity.dll + packages\System.Drawing.Common.6.0.0-preview.3.21201.4\lib\net461\System.Drawing.Common.dll @@ -96,6 +81,7 @@ + @@ -117,6 +103,10 @@ MainWindow.xaml Code + + Designer + MSBuild:Compile + @@ -141,9 +131,18 @@ SettingsSingleFileGenerator Settings.Designer.cs + + + + + + + + + \ No newline at end of file diff --git a/MainWindow.xaml b/MainWindow.xaml index 6441e16..f43a993 100644 --- a/MainWindow.xaml +++ b/MainWindow.xaml @@ -9,33 +9,10 @@ xmlns:util="clr-namespace:GeekDesk.Util" xmlns:DraggAnimatedPanel="clr-namespace:DraggAnimatedPanel" x:Name="window" xmlns:hc="https://handyorg.github.io/handycontrol" - Title="MainWindow" Height="500" Width="600"> + Title="MainWindow" Height="500" Width="600" + > - - - - - - - - - @@ -124,25 +94,49 @@ - + + - + - - + + + + + + --> - + + --> - + diff --git a/Fonts/iconfont.css b/Fonts/iconfont.css deleted file mode 100644 index b6a60c0..0000000 --- a/Fonts/iconfont.css +++ /dev/null @@ -1,137 +0,0 @@ -@font-face { - font-family: "iconfont"; /* Project id 2491374 */ - /* Color fonts */ - src: - url('data:application/x-font-woff2;charset=utf-8;base64,d09GMgABAAAAABtUAAwAAAAANTgAABsAAAEAAAAAAAAAAAAAAAAAAAAAAAAAAAAAIoQCI2YGYACBfArYfMEcATYCJAODKAuBZgAEIAWBfAcgG50nRQdzjwOFqXZK9n+ZwI0hUh/YJ8rod2vL6EahOMR4KIQwwCxPi1YVXFiHeCaK4zoCG+EIDDwchEv5XDn4cUMpf+Dn1vvbWP5tf+yvkhpjwAYIIzfokZIlMMAKwABBJI0rVNAGC8xAT4zmDqvQRq4w+moEw61jw6d8QWq2BEvp8r81Nf3AgtTyQGCXjUkJYKCA7It9ta4jjaFlm4sUO8gduO7bAPDl17Jkl3/+UEmaCktELzaxnSkcqROyJ+QJtVAZ5s2wcGn//3SW7cyhHIQOAOpNqnupLl2qcmYsJf6SDJLt3Z1FybsHsywvygGGKtwlVzQzxzqUDq2gHaQuaQquUxR9VOfakd+tBacSDxbZlCATZXRQOO8gmBfvTRICgByABXBmxwBAiJJASAQH7G7fDE4WIRQxQpUQaXICXUlgqBHUgcLUIiy3cxq2FwHzQTjjEHtfKjdEujRuQnjmS/NDpyAivTAyRFFDHDMlcSGND1mCdLQ88WhF0melBFABqLkOHEd7J4YzzwVAg7oy6vRB3QB0PA+eJ6KnGehedG96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Zwj3KtUwE/UVtB+D/T1kAAAAA') format('woff2'), - url('iconfont.woff?t=1623737923396') format('woff'), - url('iconfont.ttf?t=1623737923396') format('truetype'); -} - -.iconfont { - font-family: "iconfont" !important; - font-size: 16px; - font-style: normal; - -webkit-font-smoothing: antialiased; - -moz-osx-font-smoothing: grayscale; -} - -.icon-huihua:before { - content: "\e614"; -} - -.icon-wenjianjia1:before { - content: "\e62e"; -} - -.icon-wenjianjia2:before { - content: "\e606"; -} - -.icon-xitong3:before { - content: "\e621"; -} - -.icon-game:before { - content: "\e681"; -} - -.icon-xitong4:before { - content: "\e63e"; -} - -.icon-ren-fanqiang:before { - content: "\e88c"; -} - -.icon-qita:before { - content: "\e600"; -} - -.icon-kaifa:before { - content: "\e618"; -} - -.icon-dakaihuihua:before { - content: "\e64a"; -} - -.icon-huihua-copy:before { - content: "\e647"; -} - -.icon-iconfontyouxihudong:before { - content: "\e636"; -} - -.icon-xitong:before { - content: "\e601"; -} - -.icon-xitong1:before { - content: "\e67c"; -} - -.icon-xiazai:before { - content: "\e617"; -} - -.icon-icon-test:before { - content: "\e60e"; -} - -.icon-xinxi:before { - content: "\e640"; -} - -.icon-xiazai1:before { - content: "\e674"; -} - -.icon-youxi:before { - content: "\e680"; -} - -.icon-wangluo:before { - content: "\e611"; -} - -.icon-kaifa-:before { - content: "\e609"; -} - -.icon-wangluo1:before { - content: "\e735"; -} - -.icon-xitong2:before { - content: "\e648"; -} - -.icon-xiazai2:before { - content: "\e6af"; -} - -.icon-kaifasheji:before { - content: "\e613"; -} - -.icon-qita1:before { - content: "\e60b"; -} - -.icon-wangluo2:before { - content: "\e70b"; -} - -.icon-developer:before { - content: "\e651"; -} - -.icon-kaifataojian:before { - content: "\e63a"; -} - -.icon-wenjianjia:before { - content: "\e7c2"; -} - diff --git a/Fonts/iconfont.js b/Fonts/iconfont.js deleted file mode 100644 index c0c66f5..0000000 --- a/Fonts/iconfont.js +++ /dev/null @@ -1 +0,0 @@ -!function(c){var l,a,h,t,i,z,o='',p=(p=document.getElementsByTagName("script"))[p.length-1].getAttribute("data-injectcss");if(p&&!c.__iconfont__svg__cssinject__){c.__iconfont__svg__cssinject__=!0;try{document.write("")}catch(c){console&&console.log(c)}}function s(){i||(i=!0,h())}l=function(){var c,l,a;(a=document.createElement("div")).innerHTML=o,o=null,(l=a.getElementsByTagName("svg")[0])&&(l.setAttribute("aria-hidden","true"),l.style.position="absolute",l.style.width=0,l.style.height=0,l.style.overflow="hidden",c=l,(a=document.body).firstChild?(l=a.firstChild).parentNode.insertBefore(c,l):a.appendChild(c))},document.addEventListener?~["complete","loaded","interactive"].indexOf(document.readyState)?setTimeout(l,0):(a=function(){document.removeEventListener("DOMContentLoaded",a,!1),l()},document.addEventListener("DOMContentLoaded",a,!1)):document.attachEvent&&(h=l,t=c.document,i=!1,(z=function(){try{t.documentElement.doScroll("left")}catch(c){return void setTimeout(z,50)}s()})(),t.onreadystatechange=function(){"complete"==t.readyState&&(t.onreadystatechange=null,s())})}(window); \ No newline at end of file diff --git a/Fonts/iconfont.json b/Fonts/iconfont.json deleted file mode 100644 index f77c09e..0000000 --- a/Fonts/iconfont.json +++ /dev/null @@ -1,219 +0,0 @@ -{ - "id": "2491374", - "name": "GeekIcon", - "font_family": "iconfont", - "css_prefix_text": "icon-", - "description": "", - "glyphs": [ - { - "icon_id": "13160269", - "name": "会话", - "font_class": "huihua", - "unicode": "e614", - "unicode_decimal": 58900 - }, - { - "icon_id": "14236852", - "name": "文件夹", - "font_class": "wenjianjia1", - "unicode": "e62e", - "unicode_decimal": 58926 - }, - { - "icon_id": "15416685", - "name": "文件夹", - "font_class": "wenjianjia2", - "unicode": "e606", - "unicode_decimal": 58886 - }, - { - "icon_id": "15711148", - "name": "系统", - "font_class": "xitong3", - "unicode": "e621", - "unicode_decimal": 58913 - }, - { - "icon_id": "18058019", - "name": "游戏", - "font_class": "game", - "unicode": "e681", - "unicode_decimal": 59009 - }, - { - "icon_id": "19977025", - "name": "系统", - "font_class": "xitong4", - "unicode": "e63e", - "unicode_decimal": 58942 - }, - { - "icon_id": "20017778", - "name": "人-翻墙", - "font_class": "ren-fanqiang", - "unicode": "e88c", - "unicode_decimal": 59532 - }, - { - "icon_id": "1250", - "name": "其它", - "font_class": "qita", - "unicode": "e600", - "unicode_decimal": 58880 - }, - { - "icon_id": "397886", - "name": "开发,代码", - "font_class": "kaifa", - "unicode": "e618", - "unicode_decimal": 58904 - }, - { - "icon_id": "511314", - "name": "打开会话", - "font_class": "dakaihuihua", - "unicode": "e64a", - "unicode_decimal": 58954 - }, - { - "icon_id": "791886", - "name": "会话", - "font_class": "huihua-copy", - "unicode": "e647", - "unicode_decimal": 58951 - }, - { - "icon_id": "1033987", - "name": "游戏", - "font_class": "iconfontyouxihudong", - "unicode": "e636", - "unicode_decimal": 58934 - }, - { - "icon_id": "1119109", - "name": "系统", - "font_class": "xitong", - "unicode": "e601", - "unicode_decimal": 58881 - }, - { - "icon_id": "1137788", - "name": "系统", - "font_class": "xitong1", - "unicode": "e67c", - "unicode_decimal": 59004 - }, - { - "icon_id": "1159887", - "name": "下载", - "font_class": "xiazai", - "unicode": "e617", - "unicode_decimal": 58903 - }, - { - "icon_id": "1629872", - "name": "文件夹", - "font_class": "icon-test", - "unicode": "e60e", - "unicode_decimal": 58894 - }, - { - "icon_id": "2006733", - "name": "会话", - "font_class": "xinxi", - "unicode": "e640", - "unicode_decimal": 58944 - }, - { - "icon_id": "2418266", - "name": "下载", - "font_class": "xiazai1", - "unicode": "e674", - "unicode_decimal": 58996 - }, - { - "icon_id": "2742683", - "name": "游戏", - "font_class": "youxi", - "unicode": "e680", - "unicode_decimal": 59008 - }, - { - "icon_id": "3879214", - "name": "网络", - "font_class": "wangluo", - "unicode": "e611", - "unicode_decimal": 58897 - }, - { - "icon_id": "3903356", - "name": "开发", - "font_class": "kaifa-", - "unicode": "e609", - "unicode_decimal": 58889 - }, - { - "icon_id": "7055665", - "name": "网络", - "font_class": "wangluo1", - "unicode": "e735", - "unicode_decimal": 59189 - }, - { - "icon_id": "8802631", - "name": "系统", - "font_class": "xitong2", - "unicode": "e648", - "unicode_decimal": 58952 - }, - { - "icon_id": "9712640", - "name": "下载", - "font_class": "xiazai2", - "unicode": "e6af", - "unicode_decimal": 59055 - }, - { - "icon_id": "9783461", - "name": "开发设计", - "font_class": "kaifasheji", - "unicode": "e613", - "unicode_decimal": 58899 - }, - { - "icon_id": "9924353", - "name": "其它", - "font_class": "qita1", - "unicode": "e60b", - "unicode_decimal": 58891 - }, - { - "icon_id": "9974441", - "name": "网络", - "font_class": "wangluo2", - "unicode": "e70b", - "unicode_decimal": 59147 - }, - { - "icon_id": "10294636", - "name": "开发", - "font_class": "developer", - "unicode": "e651", - "unicode_decimal": 58961 - }, - { - "icon_id": "11121465", - "name": "开发套件", - "font_class": "kaifataojian", - "unicode": "e63a", - "unicode_decimal": 58938 - }, - { - "icon_id": "11759969", - "name": "文件夹", - "font_class": "wenjianjia", - "unicode": "e7c2", - "unicode_decimal": 59330 - } - ] -} diff --git a/GeekDesk.csproj b/GeekDesk.csproj index c3996bd..16c42f0 100644 --- a/GeekDesk.csproj +++ b/GeekDesk.csproj @@ -37,6 +37,9 @@ 4 true + + GeekDesk.SvgToGeometry + packages\SharpShellTools.2.2.0.0\lib\Apex.WinForms.dll @@ -56,8 +59,11 @@ packages\GlobalHotKey.1.1.0\lib\GlobalHotKey.dll - - packages\HandyControl.3.1.0\lib\net452\HandyControl.dll + + packages\HandyControl.3.2.0\lib\net472\HandyControl.dll + + + packages\Newtonsoft.Json.13.0.1\lib\net45\Newtonsoft.Json.dll packages\SharpShellTools.2.2.0.0\lib\ServerManager.exe @@ -148,6 +154,7 @@ + @@ -254,8 +261,12 @@ ResXFileCodeGenerator Resources.Designer.cs - - + + PreserveNewest + + + PreserveNewest + SettingsSingleFileGenerator @@ -273,8 +284,6 @@ - - diff --git a/Resource/Dictionary/Geometry.xaml b/Resource/Dictionary/Geometry.xaml index d9fe4fd..d5d66e2 100644 --- a/Resource/Dictionary/Geometry.xaml +++ b/Resource/Dictionary/Geometry.xaml @@ -1,6 +1,6 @@  + > M512 992C246.912 992 32 777.088 32 512 32 246.912 246.912 32 512 32c265.088 0 480 214.912 480 480 0 265.088-214.912 480-480 480z m-59.072-512v236.32a54.144 54.144 0 1 0 108.288 0V480a54.144 54.144 0 1 0-108.288 0z m53.76-226.464c-14.72 0-27.232 4.544-37.568 15.136-11.04 9.856-16.192 22.72-16.192 38.656 0 15.136 5.152 28 16.192 38.624 10.336 10.592 22.848 15.904 37.6 15.904a57.6 57.6 0 0 0 39.04-15.168c10.304-10.592 15.456-23.456 15.456-39.36s-5.12-28.8-15.456-38.656c-10.304-10.56-23.584-15.136-39.04-15.136z diff --git a/SvgToGeometry.cs b/SvgToGeometry.cs new file mode 100644 index 0000000..ec2a831 --- /dev/null +++ b/SvgToGeometry.cs @@ -0,0 +1,73 @@ +using Newtonsoft.Json; +using Newtonsoft.Json.Linq; +using System; +using System.Collections.Generic; +using System.IO; +using System.Linq; +using System.Security.Cryptography; +using System.Text; +using System.Threading.Tasks; +using System.Xml; + +namespace GeekDesk +{ + class SvgToGeometry + { + static void Main(string[] args) + { + XmlDocument xmlDoc = new XmlDocument(); + xmlDoc.XmlResolver = null; + XmlReaderSettings settings = new XmlReaderSettings(); + settings.IgnoreComments = true;//忽略文档里面的注释 + settings.DtdProcessing = DtdProcessing.Parse; + XmlReader reader = XmlReader.Create("D:\\下载文件\\font_2642707_zjdi9qttb38\\iconfont.svg", settings); + xmlDoc.Load(reader); + + XmlNodeList nodeList = xmlDoc.SelectNodes("/svg/defs/font/glyph"); + + string jsonFilePath = "D:\\下载文件\\font_2642707_zjdi9qttb38\\iconfont.json"; + JObject jo = ReadJson(jsonFilePath); + JArray ja = JArray.Parse(jo["glyphs"].ToString()); + + string value; + + for (int i=0; i`p6Q-RGLy+dlF4M51SSNSKoUY0m>@_b zEG7;Z5JkE2FvzAXdJ%~NiYR)05D-xj6!FUTyewB7;=QQ6`y?Rg<^Ah)P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PJJ88Xn zWV1(>Zyebd7#eEj^7@I10~4}WDNIZhG?$DQCt-oC!d;n43N$^GcO%b;6Qw$w!<%6K z4+7vw(CDW$;1;~`?rP+%fL}*;!1wqOXqv5Nyo;>GjBg_!!>n&2A0;``jnyvx=AzHl z2qz(TVwLBCJ zmq)D|_dW{!-H+G{DchjEhmrR~Cs4dkj3CzG+2^>yE=E2GiBa^o1Z~6kR-L22F+iH2 z=PC65O2je9mBM;hjW_|GlL#r$O{1S?^wI*JGN7FWycL|ap)B}3hu=? zau`J(p@1Mb6@215Z+r!2Cj-b2BFup_;6=r^^Hz8%t>E7Z?g@Cu|4qP%7J}DB$S+2K zUje)ma885;2Wyvre**6DzfT~ORglbT^gj*>tbx4NqI@#KDX5=7SOVX z0O3Le@zXIz9jRCcP-eAjg0;$yNUgK8v)0?&TZ5`aDAd+2TU=YZbZM>j&9$|^y!24* z-wyr0wuk(ow&quVtxf#pueIy1#}|}etkt}a)oKe~sMQ|+L#=lGpYVQzA0ht}S7{0h literal 0 HcmV?d00001 diff --git a/packages.config b/packages.config index 774c9a1..64fa6cf 100644 --- a/packages.config +++ b/packages.config @@ -2,8 +2,9 @@ - + + From ccd00afbb2a59629685b02b6d80f39128b3e5da7 Mon Sep 17 00:00:00 2001 From: liufei Date: Wed, 7 Jul 2021 17:28:29 +0800 Subject: [PATCH 22/29] =?UTF-8?q?=E6=B7=BB=E5=8A=A0=20=E8=87=AA=E5=AE=9A?= =?UTF-8?q?=E4=B9=89=E8=8F=9C=E5=8D=95=E5=9B=BE=E6=A0=87?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Control/Other/IconInfoDialog.xaml | 2 +- Control/UserControls/IconFont/IconPannel.xaml | 45 ++ .../UserControls/IconFont/IconPannel.xaml.cs | 29 + .../PannelCard/LeftCardControl.xaml | 9 +- .../PannelCard/LeftCardControl.xaml.cs | 6 +- .../PannelCard/RightCardControl.xaml | 2 +- Control/Windows/ConfigWindow.xaml | 2 +- Control/Windows/IconfontWindow.xaml | 41 ++ Control/Windows/IconfontWindow.xaml.cs | 91 +++ GeekDesk.csproj | 29 +- MainWindow.xaml | 18 +- MainWindow.xaml.cs | 16 +- Resource/Iconfont/iconfont.js | 1 + Resource/Iconfont/iconfont.js.bak | 294 +++++++++ Resource/Iconfont/iconfont.json | 604 ++++++++++++++++++ SvgToGeometry.cs | 73 --- Util/AeroGlassHelper.cs | 175 +++++ Util/ImageUtil.cs | 17 + Util/ScreenUtil.cs | 15 - Util/SvgToGeometry.cs | 83 +++ ViewModel/AppConfig.cs | 2 + ViewModel/IconfontInfo.cs | 40 ++ packages.config | 2 +- 23 files changed, 1489 insertions(+), 107 deletions(-) create mode 100644 Control/UserControls/IconFont/IconPannel.xaml create mode 100644 Control/UserControls/IconFont/IconPannel.xaml.cs create mode 100644 Control/Windows/IconfontWindow.xaml create mode 100644 Control/Windows/IconfontWindow.xaml.cs create mode 100644 Resource/Iconfont/iconfont.js create mode 100644 Resource/Iconfont/iconfont.js.bak create mode 100644 Resource/Iconfont/iconfont.json delete mode 100644 SvgToGeometry.cs create mode 100644 Util/AeroGlassHelper.cs delete mode 100644 Util/ScreenUtil.cs create mode 100644 Util/SvgToGeometry.cs create mode 100644 ViewModel/IconfontInfo.cs diff --git a/Control/Other/IconInfoDialog.xaml b/Control/Other/IconInfoDialog.xaml index 85f8838..59e7403 100644 --- a/Control/Other/IconInfoDialog.xaml +++ b/Control/Other/IconInfoDialog.xaml @@ -2,7 +2,7 @@ xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" xmlns:hc="https://handyorg.github.io/handycontrol" - CornerRadius="10" + CornerRadius="4" Width="300" Height="300" Opacity="0.9"> diff --git a/Control/UserControls/IconFont/IconPannel.xaml b/Control/UserControls/IconFont/IconPannel.xaml new file mode 100644 index 0000000..9de1c89 --- /dev/null +++ b/Control/UserControls/IconFont/IconPannel.xaml @@ -0,0 +1,45 @@ + + + + + + + + + + + + + + + + + --> - _swap; @@ -190,7 +193,8 @@ namespace GeekDesk.Control.UserControls.PannelCard /// private void EditMenuGeometry(object sender, RoutedEventArgs e) { - + MenuInfo menuInfo = ((MenuItem)sender).Tag as MenuInfo; + IconfontWindow.Show(SvgToGeometry.GetIconfonts(), menuInfo); } } } diff --git a/Control/UserControls/PannelCard/RightCardControl.xaml b/Control/UserControls/PannelCard/RightCardControl.xaml index 101c830..a9cc785 100644 --- a/Control/UserControls/PannelCard/RightCardControl.xaml +++ b/Control/UserControls/PannelCard/RightCardControl.xaml @@ -52,7 +52,7 @@ Effect="{DynamicResource EffectShadow2}" Margin="5,0,5,5" Grid.ColumnSpan="2"> - + diff --git a/Control/Windows/ConfigWindow.xaml b/Control/Windows/ConfigWindow.xaml index 5a62658..a061841 100644 --- a/Control/Windows/ConfigWindow.xaml +++ b/Control/Windows/ConfigWindow.xaml @@ -62,7 +62,7 @@