mirror of
https://github.com/1j01/textual-paint.git
synced 2024-10-27 01:41:29 +03:00
Fix status bar showing -100, -100 value I used for color updates
This commit is contained in:
parent
d229bc4108
commit
ba4d023387
@ -2545,7 +2545,10 @@ Columns: {len(self.palette) // 2}
|
||||
event.stop()
|
||||
self.cancel_preview()
|
||||
|
||||
self.get_widget_by_id("status_coords", Static).update(f"{event.x},{event.y}")
|
||||
# -100, -100 is a "sentinel value" for no mouse position (hacky)
|
||||
# TODO: add an attribute to ToolPreviewUpdate or make it's x/y Optional
|
||||
if event.x >= 0:
|
||||
self.get_widget_by_id("status_coords", Static).update(f"{event.x},{event.y}")
|
||||
|
||||
if self.selected_tool in [Tool.brush, Tool.pencil, Tool.eraser, Tool.curve, Tool.polygon]:
|
||||
if self.selected_tool == Tool.curve:
|
||||
|
Loading…
Reference in New Issue
Block a user