Logic fix

This commit is contained in:
MikeTheWatchGuy 2018-12-19 10:11:47 -05:00
parent 36b2ef27d6
commit b048b05687
1 changed files with 2 additions and 2 deletions

View File

@ -20,6 +20,6 @@ while True: # Event Loop
event, values = window.Read()
if event in (None, 'Exit'):
break
if len(values['_INPUT_']) and values['_INPUT_'][-1] not in ('0123456789'): # if last char entered not a digit
window.Element('_INPUT_').Update(values['_INPUT_'][:-1]) # delete last char from input
if len(values['_INPUT_']) and values['_INPUT_'][-1] not in ('0123456789'): # if last char entered not a digit
window.Element('_INPUT_').Update(values['_INPUT_'][:-1]) # delete last char from input
window.Close()