diff options
author | Victor Cubas <vhcubas91@gmail.com> | 2013-01-24 20:48:09 (GMT) |
---|---|---|
committer | Victor Cubas <vhcubas91@gmail.com> | 2013-01-24 20:48:09 (GMT) |
commit | 91b9b2cf986f9e3812165150daa4ed7dcbb767dd (patch) | |
tree | 1cc4d471a712979e2138d79532ee54f95f8d3547 | |
parent | 3bfc9821b1548dd9162f07fd2a1ee2593077e20f (diff) |
Agregamos incono
-rw-r--r-- | activity.py | 43 |
1 files changed, 19 insertions, 24 deletions
diff --git a/activity.py b/activity.py index ff46269..de7dfef 100644 --- a/activity.py +++ b/activity.py @@ -132,34 +132,29 @@ class PiensaEscribeActivity(activity.Activity): vbox.show_all() def resetear(self, imagen1, imagen2, button1, button2, button3): - imagen1.set_from_file(listImagenes[self.indice_imagen]) - self.indice_imagen += 1 - imagen2.set_from_file(listImagenes[self.indice_imagen]) - self.indice_imagen += 1 + imagen1.set_from_file(listImagenes[self.indice_imagen]) + self.indice_imagen += 1 + imagen2.set_from_file(listImagenes[self.indice_imagen]) + self.indice_imagen += 1 - button1.set_label(label_opciones[self.indice_opciones]) - self.indice_opciones += 1 - button2.set_label(label_opciones[self.indice_opciones]) - self.indice_opciones += 1 - button3.set_label(label_opciones[self.indice_opciones]) - self.indice_opciones += 1 - print self.indice_resp_correcta - self.indice_resp_correcta += 1 - print self.indice_resp_correcta + button1.set_label(label_opciones[self.indice_opciones]) + self.indice_opciones += 1 + button2.set_label(label_opciones[self.indice_opciones]) + self.indice_opciones += 1 + button3.set_label(label_opciones[self.indice_opciones]) + self.indice_opciones += 1 + self.indice_resp_correcta += 1 + def __correcto_cb(self, button, clave, imagen1, imagen2, button1, button2, button3): - if button.get_label() == clave: - #print clave - voice.say('Opcion correcta') - #self.indice_resp_correcta += 1 - self.resetear(imagen1, imagen2, button1, button2, button3) - print self.indice_resp_correcta - else: - print clave - voice.say('Opcion incorrecta') + if button.get_label() == clave: + #print clave + voice.say('Opcion correcta') + #self.indice_resp_correcta += 1 + self.resetear(imagen1, imagen2, button1, button2, button3) + else: + voice.say('Opcion incorrecta') def __sobre_boton_cb(self, button): voice.say(button.get_label()) - - |