(self, event)
| 141 | writer.writerow([item.ID, override.attrID, override.value]) |
| 142 | |
| 143 | def OnClear(self, event): |
| 144 | with wx.MessageDialog( |
| 145 | self, |
| 146 | _t("Are you sure you want to delete all overrides?"), |
| 147 | _t("Confirm Delete"), |
| 148 | wx.YES | wx.NO | wx.ICON_EXCLAMATION |
| 149 | ) as dlg: |
| 150 | if dlg.ShowModal() == wx.ID_YES: |
| 151 | sMkt = Market.getInstance() |
| 152 | items = sMkt.getItemsWithOverrides() |
| 153 | # We can't just delete overrides, as loaded items will still have |
| 154 | # them assigned. Deleting them from the database won't propagate |
| 155 | # them due to the eve/user database disconnect. We must loop through |
| 156 | # all items that have overrides and remove them |
| 157 | for item in items: |
| 158 | for _, x in list(item.overrides.items()): |
| 159 | item.deleteOverride(x.attr) |
| 160 | self.itemView.updateItems(True) |
| 161 | self.pg.Clear() |
| 162 | |
| 163 | |
| 164 | # This is literally a stripped down version of the market. |
nothing calls this directly
no test coverage detected