fix: 画好的多边形颜色改变

This commit is contained in:
2026-03-03 01:00:06 +08:00
parent 02c18c7387
commit 1174019eff

View File

@@ -1003,7 +1003,7 @@ impl PaintApp {
if idx >= self.tool_states.len() {
return;
}
if self.tool_selected == Tool::Polygon {
if self.tool_selected == Tool::Polygon && self.control_state != ControlState::Zero {
// 切换到其他工具,闭合路径
self.canvas.close_path();
self.canvas.stroke();