Filter out unwanted groups in shipbrowser

This commit is contained in:
HomeWorld
2010-10-30 23:31:56 +03:00
parent 6740f7eb58
commit e3203c588a

View File

@@ -36,6 +36,7 @@ class ShipBrowser(wx.Panel):
self._stage3ShipName = ""
self.fitIDMustEditName = -1
self.filterShipsWithNoFits = False
self.filterGroups = [1022]
self.SetSizeHintsSz(wx.DefaultSize, wx.DefaultSize)
@@ -103,7 +104,8 @@ class ShipBrowser(wx.Panel):
self.categoryList = sMarket.getShipRoot()
self.categoryList.sort(key=self.nameKey)
for ID, name in self.categoryList:
self.lpane.AddWidget(CategoryItem(self.lpane, ID, (name, 0)))
if ID not in self.filterGroups:
self.lpane.AddWidget(CategoryItem(self.lpane, ID, (name, 0)))
self.lpane.RefreshList()
self.Show()