dialogs/LDElementDialog.py
changeset 1767 c74815729afd
parent 1745 f9d32913bad4
child 1768 691083b5682a
equal deleted inserted replaced
1766:c1e5b9f19483 1767:c74815729afd
    70         element_modifiers = ([CONTACT_NORMAL, CONTACT_REVERSE,
    70         element_modifiers = ([CONTACT_NORMAL, CONTACT_REVERSE,
    71                               CONTACT_RISING, CONTACT_FALLING]
    71                               CONTACT_RISING, CONTACT_FALLING]
    72                              if type == "contact"
    72                              if type == "contact"
    73                              else [COIL_NORMAL, COIL_REVERSE, COIL_SET,
    73                              else [COIL_NORMAL, COIL_REVERSE, COIL_SET,
    74                                    COIL_RESET, COIL_RISING, COIL_FALLING])
    74                                    COIL_RESET, COIL_RISING, COIL_FALLING])
    75         modifiers_label = [_("Normal"), _("Negated")] + \
    75         modifiers_label = \
    76                           ([_("Set"), _("Reset")] if type == "coil" else []) + \
    76             [_("Normal"), _("Negated")] + \
    77                           [_("Rising Edge"), _("Falling Edge")]
    77             ([_("Set"), _("Reset")] if type == "coil" else []) + \
       
    78             [_("Rising Edge"), _("Falling Edge")]
    78 
    79 
    79         for modifier, label in zip(element_modifiers, modifiers_label):
    80         for modifier, label in zip(element_modifiers, modifiers_label):
    80             radio_button = wx.RadioButton(self, label=label,
    81             radio_button = wx.RadioButton(self, label=label,
    81                   style=(wx.RB_GROUP if first else 0))
    82                   style=(wx.RB_GROUP if first else 0))
    82             radio_button.SetValue(first)
    83             radio_button.SetValue(first)