code: def onSelectRow(self, event):
          
          grid = self.grid
          row = event.Row
          default = (255, 255, 255, 255)
          highlight = (191, 216, 216, 255)
          cell_color = grid.GetCellBackgroundColour(row, 0)
          attr = wx.grid.GridCellAttr()
          if cell_color == default:
              attr.SetBackgroundColour(highlight)
              self.selected_rows.add(row)
          else:
              attr.SetBackgroundColour(default)
              try:
                  self.selected_rows.remove(row)
              except KeyError:
                  pass
          if self.selected_rows and self.deleteRowButton:
              self.deleteRowButton.Enable()
          else:
              self.deleteRowButton.Disable()
          grid.SetRowAttr(row, attr)
          grid.Refresh()
docs: Highlight or unhighlight a row for possible deletion.