Make sure order of options doesn't depend on order of options in memory (which can be random as it's dict)
This commit is contained in:
@@ -64,10 +64,10 @@ class CopySelectDialog(wx.Dialog):
|
||||
if format == "EFT":
|
||||
bsizer = wx.BoxSizer(wx.VERTICAL)
|
||||
|
||||
for x, v in EFT_OPTIONS.items():
|
||||
ch = wx.CheckBox(self, -1, v['name'])
|
||||
self.options[x] = ch
|
||||
if self.settings['options'] & x:
|
||||
for optId, optName, optDesc in EFT_OPTIONS:
|
||||
ch = wx.CheckBox(self, -1, optName)
|
||||
self.options[optId] = ch
|
||||
if self.settings['options'] & optId:
|
||||
ch.SetValue(True)
|
||||
bsizer.Add(ch, 1, wx.EXPAND | wx.TOP | wx.BOTTOM, 3)
|
||||
mainSizer.Add(bsizer, 1, wx.EXPAND | wx.LEFT, 20)
|
||||
|
||||
@@ -51,16 +51,10 @@ MODULE_CATS = ('Module', 'Subsystem', 'Structure Module')
|
||||
SLOT_ORDER = (Slot.LOW, Slot.MED, Slot.HIGH, Slot.RIG, Slot.SUBSYSTEM, Slot.SERVICE)
|
||||
OFFLINE_SUFFIX = '/OFFLINE'
|
||||
|
||||
EFT_OPTIONS = {
|
||||
Options.IMPLANTS.value: {
|
||||
'name': 'Implants && Boosters',
|
||||
'description': 'Exports implants and boosters'
|
||||
},
|
||||
Options.MUTATIONS.value: {
|
||||
'name': 'Mutated Attributes',
|
||||
'description': 'Exports mutated modules\' stats'
|
||||
}
|
||||
}
|
||||
EFT_OPTIONS = (
|
||||
(Options.IMPLANTS.value, 'Implants && Boosters', 'Exports implants and boosters'),
|
||||
(Options.MUTATIONS.value, 'Mutated Attributes', 'Exports mutated modules\' stats'),
|
||||
)
|
||||
|
||||
|
||||
def exportEft(fit, options):
|
||||
|
||||
Reference in New Issue
Block a user