Merge branch 'master' of evefit.org:pyfa
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
__all__ = ["moduleState", "moduleNameOrSlot", "attributeDisplay", "maxRange",
|
||||
__all__ = ["moduleState", "moduleName", "attributeDisplay", "maxRange",
|
||||
"name", "droneDps", "droneNameAmount", "droneCheckbox", "moduleAmmo",
|
||||
"capacitorUse", "activityCheckbox", "moduleAmmoIcon", "modulePrice",
|
||||
"projectedName", "projectedState", "projectedAmmoIcon", "projectedAmmo",
|
||||
|
||||
@@ -37,7 +37,7 @@ class CapacitorUse(ViewColumn):
|
||||
|
||||
def getText(self, mod):
|
||||
capUse = mod.capUse
|
||||
if capUse is not None:
|
||||
if capUse:
|
||||
return "%s%s" % ("+" if capUse < 0 else "", (formatAmount(-capUse, 3, 0, 3)))
|
||||
else:
|
||||
return ""
|
||||
|
||||
@@ -22,8 +22,8 @@ from gui.viewColumn import ViewColumn
|
||||
from gui import bitmapLoader
|
||||
from eos.types import Slot
|
||||
|
||||
class ModuleNameOrSlot(ViewColumn):
|
||||
name = "Module name/slot"
|
||||
class ModuleName(ViewColumn):
|
||||
name = "Module Name"
|
||||
def __init__(self, fittingView, params):
|
||||
ViewColumn.__init__(self, fittingView)
|
||||
self.columnText = "Name"
|
||||
@@ -51,4 +51,4 @@ class ModuleNameOrSlot(ViewColumn):
|
||||
|
||||
return iconId
|
||||
|
||||
ModuleNameOrSlot.register()
|
||||
ModuleName.register()
|
||||
@@ -39,12 +39,12 @@ class ModulePrice(ViewColumn):
|
||||
|
||||
sMarket = service.Market.getInstance()
|
||||
price = sMarket.getPriceNow(mod.item.ID).price
|
||||
return formatAmount(price, 3, 3, 9) if price is not None else False
|
||||
return formatAmount(price, 3, 3, 9) if price else False
|
||||
|
||||
def delayedText(self, mod, display, colItem):
|
||||
def callback(requests):
|
||||
price = requests[0].price
|
||||
colItem.SetText(formatAmount(price, 3, 3, 9) if price is not None else "")
|
||||
colItem.SetText(formatAmount(price, 3, 3, 9) if price else "")
|
||||
display.SetItem(colItem)
|
||||
|
||||
|
||||
|
||||
@@ -23,7 +23,7 @@ from gui import bitmapLoader
|
||||
from eos.types import State
|
||||
|
||||
class ModuleState(ViewColumn):
|
||||
name = "Module state"
|
||||
name = "Module State"
|
||||
def __init__(self, fittingView, params):
|
||||
ViewColumn.__init__(self, fittingView)
|
||||
self.resizable = False
|
||||
|
||||
@@ -30,9 +30,9 @@ from gui.builtinViewColumns.moduleState import ModuleState
|
||||
FitChanged, FIT_CHANGED = wx.lib.newevent.NewEvent()
|
||||
|
||||
class FittingView(d.Display):
|
||||
DEFAULT_COLS = ["Module state",
|
||||
DEFAULT_COLS = ["Module State",
|
||||
"Module Ammo Icon",
|
||||
"Module name/slot",
|
||||
"Module Name",
|
||||
"attr:power",
|
||||
"attr:cpu",
|
||||
"Max range",
|
||||
|
||||
@@ -27,8 +27,8 @@ from gui.contextMenu import ContextMenu
|
||||
import eos.types
|
||||
|
||||
class ProjectedView(d.Display):
|
||||
DEFAULT_COLS = ["Projected Ammo Icon",
|
||||
"Projected State",
|
||||
DEFAULT_COLS = ["Projected State",
|
||||
"Projected Ammo Icon",
|
||||
"Projected Name",
|
||||
"Projected Ammo"]
|
||||
|
||||
|
||||
Reference in New Issue
Block a user