Exports skills needed for active fit and active character
(self, event)
| 803 | dlg.ShowModal() |
| 804 | |
| 805 | def exportSkillsNeeded(self, event): |
| 806 | """ Exports skills needed for active fit and active character """ |
| 807 | sCharacter = Character.getInstance() |
| 808 | with wx.FileDialog( |
| 809 | self, |
| 810 | _t("Export Skills Needed As..."), |
| 811 | wildcard=("|".join([ |
| 812 | _t("EVEMon skills training file") + " (*.emp)|*.emp", |
| 813 | _t("EVEMon skills training XML file") + " (*.xml)|*.xml", |
| 814 | _t("Text skills training file") + " (*.txt)|*.txt" |
| 815 | ])), |
| 816 | style=wx.FD_SAVE | wx.FD_OVERWRITE_PROMPT, |
| 817 | ) as dlg: |
| 818 | if dlg.ShowModal() == wx.ID_OK: |
| 819 | saveFmtInt = dlg.GetFilterIndex() |
| 820 | |
| 821 | if saveFmtInt == 0: # Per ordering of wildcards above |
| 822 | saveFmt = "emp" |
| 823 | elif saveFmtInt == 1: |
| 824 | saveFmt = "xml" |
| 825 | else: |
| 826 | saveFmt = "txt" |
| 827 | |
| 828 | filePath = dlg.GetPath() |
| 829 | if '.' not in os.path.basename(filePath): |
| 830 | filePath += ".{0}".format(saveFmt) |
| 831 | |
| 832 | self.waitDialog = wx.BusyInfo(_t("Exporting skills needed..."), parent=self) |
| 833 | sCharacter.backupSkills(filePath, saveFmt, self.getActiveFit(), self.closeWaitDialog) |
| 834 | |
| 835 | def fileImportDialog(self, event): |
| 836 | """Handles importing single/multiple EVE XML / EFT cfg fit files""" |
nothing calls this directly
no test coverage detected