"Cannot call this method on an empty rect" when holding backspace to delete formula characters on a slower machine
Opened this issue · 1 comments
wh1t3cAt1k commented
Reproduces reliably in PopupListWatcher for me when I am using a slower virtual machine and quickly delete formula symbols up until the opening bracket disappears (=FUNCTION("blah-blah"
=>>> =FUNCTION
)
It seems harmless otherwise, does not crash the app (probably due to a try/catch up the stack), but I wonder if it should be handled more gracefully.
govert commented
I can't reproduce it myself, but I do find weird things happening from time to time, especially when debugging. So I'm happy to find one you can pin down - thank you!
I guess for this case we can just add a check to the condition:
if (string.IsNullOrEmpty(text) || itemBounds == Rect.Empty)