Add some code to populate the fitting view with empty dummies when a fit is selected.

This commit is contained in:
cncfanatics
2010-08-27 10:37:47 +02:00
parent daba65a1f6
commit 351357d434
5 changed files with 35 additions and 8 deletions

View File

@@ -34,13 +34,16 @@ class ModuleState(ViewColumn):
continue
id = State.__dict__[state]
self.stateNameMap[id] = state
self.stateNameMap[id] = state.lower()
def getText(self, mod):
return ""
def getImageId(self, mod):
bitmap = bitmapLoader.getBitmap("state_%s_small" % self.stateNameMap[mod.state], "icons")
return self.fittingView.imageList.Add(bitmap)
if mod.isEmpty():
return -1
else:
bitmap = bitmapLoader.getBitmap("state_%s_small" % self.stateNameMap[mod.state], "icons")
return self.fittingView.imageList.Add(bitmap)
builtinViewColumns.registerColumn(ModuleState)