Skip to content
Snippets Groups Projects
Commit a6c4ff6b authored by Santiago Freire Lopez's avatar Santiago Freire Lopez
Browse files

added morse guide command in keyboard module

parent 992b69ba
No related branches found
No related tags found
No related merge requests found
......@@ -95,7 +95,8 @@ morse = {
#Comandos especiales del programa
'.-.-': 'EOM',
'---.': 'MAYUS',
'------' : 'SALIR',
'---.-': 'GUIA',
'------': 'SALIR',
}
......
......@@ -210,7 +210,7 @@ def keyboard(window,salgo):
cambiarTextoGUI('_TRANSLATION_',window,resCaracter)
#Si no recibí ningún caracter especial, presiono la tecla.
if resCaracter not in {None,'EOM','eom','MAYUS','mayus','SALIR','salir'}:
if resCaracter not in {None,'EOM','eom','MAYUS','mayus','GUIA','guia','SALIR','salir'}:
#Si los caracteres están en los que puede insertar pyautogui, presiono la tecla.
if resCaracter not in dicts.cEsp:
......@@ -237,6 +237,10 @@ def keyboard(window,salgo):
mayus = 1
resCaracter = None
#Para abrir la guía Morse
elif resCaracter in {'GUIA','guia'}:
subprocess.call(['xdg-open', 'guide.jpg'])
#Para salir del programa
elif resCaracter in {'SALIR','salir'}:
sg.PopupAutoClose('Saliendo del programa.', keep_on_top=True, title='Aviso')
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment