ignore 'name' mode in a few places

This commit is contained in:
Kartik K. Agaram 2022-05-30 15:28:50 -07:00
parent 1552efd76d
commit 096f6255b2
1 changed files with 4 additions and 0 deletions

View File

@ -219,6 +219,8 @@ function Drawing.mouse_pressed(drawing, x,y, button)
drawing.pending = {mode=Current_drawing_mode, center=j}
elseif Current_drawing_mode == 'move' then
-- all the action is in mouse_released
elseif Current_drawing_mode == 'name' then
-- all the action is in mouse_released
else
print(Current_drawing_mode)
assert(false)
@ -332,6 +334,8 @@ function Drawing.mouse_released(x,y, button)
Lines.current.pending.end_angle = geom.angle_with_hint(center.x,center.y, mx,my, Lines.current.pending.end_angle)
table.insert(Lines.current.shapes, Lines.current.pending)
end
elseif Lines.current.pending.mode == 'name' then
-- all the action is in mouse_released
else
print(Lines.current.pending.mode)
assert(false)