(self, event)
| 142 | wx.PostEvent(self.entityChoices, wx.CommandEvent(wx.wxEVT_COMMAND_CHOICE_SELECTED)) |
| 143 | |
| 144 | def OnDelete(self, event): |
| 145 | with wx.MessageDialog( |
| 146 | self, "Do you really want to delete the {} {}?".format(self.getActiveEntity().name, self.entityName), |
| 147 | "Confirm Delete", wx.YES | wx.NO | wx.ICON_QUESTION |
| 148 | ) as dlg: |
| 149 | dlg.CenterOnParent() |
| 150 | if dlg.ShowModal() == wx.ID_YES: |
| 151 | self.DoDelete(self.getActiveEntity()) |
| 152 | self.refreshEntityList() |
| 153 | wx.PostEvent(self.entityChoices, wx.CommandEvent(wx.wxEVT_COMMAND_CHOICE_SELECTED)) |
| 154 | |
| 155 | def refreshEntityList(self, selected=None): |
| 156 | self.choices = self.getEntitiesFromContext() |
nothing calls this directly
no test coverage detected