improve:几何长按状态显示

This commit is contained in:
2025-12-20 17:30:18 +08:00
parent 71cbe12cee
commit bbb30b7c25
+25 -10
View File
@@ -154,8 +154,11 @@ namespace Ink_Canvas
if (isLongPressSelected) if (isLongPressSelected)
{ {
if (ToggleSwitchDrawShapeBorderAutoHide.IsOn) CollapseBorderDrawShape(); if (ToggleSwitchDrawShapeBorderAutoHide.IsOn) CollapseBorderDrawShape();
var dA = new DoubleAnimation(1, 1, new Duration(TimeSpan.FromMilliseconds(0))); if (sender is UIElement ui)
ImageDrawLine.BeginAnimation(OpacityProperty, dA); {
var dA = new DoubleAnimation(1, 1, new Duration(TimeSpan.FromMilliseconds(0)));
ui.BeginAnimation(OpacityProperty, dA);
}
} }
DrawShapePromptToPen(); DrawShapePromptToPen();
@@ -177,8 +180,11 @@ namespace Ink_Canvas
if (isLongPressSelected) if (isLongPressSelected)
{ {
if (ToggleSwitchDrawShapeBorderAutoHide.IsOn) CollapseBorderDrawShape(); if (ToggleSwitchDrawShapeBorderAutoHide.IsOn) CollapseBorderDrawShape();
var dA = new DoubleAnimation(1, 1, new Duration(TimeSpan.FromMilliseconds(0))); if (sender is UIElement ui)
ImageDrawDashedLine.BeginAnimation(OpacityProperty, dA); {
var dA = new DoubleAnimation(1, 1, new Duration(TimeSpan.FromMilliseconds(0)));
ui.BeginAnimation(OpacityProperty, dA);
}
} }
DrawShapePromptToPen(); DrawShapePromptToPen();
@@ -200,8 +206,11 @@ namespace Ink_Canvas
if (isLongPressSelected) if (isLongPressSelected)
{ {
if (ToggleSwitchDrawShapeBorderAutoHide.IsOn) CollapseBorderDrawShape(); if (ToggleSwitchDrawShapeBorderAutoHide.IsOn) CollapseBorderDrawShape();
var dA = new DoubleAnimation(1, 1, new Duration(TimeSpan.FromMilliseconds(0))); if (sender is UIElement ui)
ImageDrawDotLine.BeginAnimation(OpacityProperty, dA); {
var dA = new DoubleAnimation(1, 1, new Duration(TimeSpan.FromMilliseconds(0)));
ui.BeginAnimation(OpacityProperty, dA);
}
} }
DrawShapePromptToPen(); DrawShapePromptToPen();
@@ -223,8 +232,11 @@ namespace Ink_Canvas
if (isLongPressSelected) if (isLongPressSelected)
{ {
if (ToggleSwitchDrawShapeBorderAutoHide.IsOn) CollapseBorderDrawShape(); if (ToggleSwitchDrawShapeBorderAutoHide.IsOn) CollapseBorderDrawShape();
var dA = new DoubleAnimation(1, 1, new Duration(TimeSpan.FromMilliseconds(0))); if (sender is UIElement ui)
ImageDrawArrow.BeginAnimation(OpacityProperty, dA); {
var dA = new DoubleAnimation(1, 1, new Duration(TimeSpan.FromMilliseconds(0)));
ui.BeginAnimation(OpacityProperty, dA);
}
} }
DrawShapePromptToPen(); DrawShapePromptToPen();
@@ -246,8 +258,11 @@ namespace Ink_Canvas
if (isLongPressSelected) if (isLongPressSelected)
{ {
if (ToggleSwitchDrawShapeBorderAutoHide.IsOn) CollapseBorderDrawShape(); if (ToggleSwitchDrawShapeBorderAutoHide.IsOn) CollapseBorderDrawShape();
var dA = new DoubleAnimation(1, 1, new Duration(TimeSpan.FromMilliseconds(0))); if (sender is UIElement ui)
ImageDrawParallelLine.BeginAnimation(OpacityProperty, dA); {
var dA = new DoubleAnimation(1, 1, new Duration(TimeSpan.FromMilliseconds(0)));
ui.BeginAnimation(OpacityProperty, dA);
}
} }
DrawShapePromptToPen(); DrawShapePromptToPen();