MCPcopy Index your code
hub / github.com/pyfa-org/Pyfa / importPatterns

Method importPatterns

gui/setEditor.py:202–222  ·  view source on GitHub ↗

Event fired when import from clipboard button is clicked

(self, event)

Source from the content-addressed store, hash-verified

200 pass
201
202 def importPatterns(self, event):
203 """Event fired when import from clipboard button is clicked"""
204
205 text = fromClipboard()
206 if text:
207 sIS = ImplantSets.getInstance()
208 try:
209 sIS.importSets(text)
210 self.stNotice.SetLabel(_t("Patterns successfully imported from clipboard"))
211 except ImportError as e:
212 pyfalog.error(e)
213 self.stNotice.SetLabel(str(e))
214 except (KeyboardInterrupt, SystemExit):
215 raise
216 except Exception as e:
217 pyfalog.error(e)
218 self.stNotice.SetLabel(_t("Could not import from clipboard: unknown errors"))
219 finally:
220 self.entityEditor.refreshEntityList()
221 else:
222 self.stNotice.SetLabel(_t("Could not import from clipboard"))
223
224 def exportPatterns(self, event):
225 """Event fired when export to clipboard button is clicked"""

Callers

nothing calls this directly

Calls 6

fromClipboardFunction · 0.90
importSetsMethod · 0.80
SetLabelMethod · 0.80
refreshEntityListMethod · 0.80
_tFunction · 0.50
getInstanceMethod · 0.45

Tested by

no test coverage detected