NovaBryan/EVE_Dump
Log | Files | 📦 下载最新源码 (.zip) | Refs | README

mapMarkerMyHome.py (1899B)


      1 #Embedded file name: C:\BuildAgent\work\20d73f1b24eed06e\eve\release\V24.01\eve\client\script\ui\shared\mapView\markers\mapMarkerMyHome.py
      2 import homestation.client
      3 import trinity
      4 from carbonui import uiconst
      5 from carbonui.primitives.sprite import Sprite
      6 from eve.client.script.ui.shared.mapView.markers.mapMarkerBase_Icon import MarkerIconBase
      7 from localization import GetByLabel
      8 from eveservices.menu import GetMenuService
      9 
     10 class MarkerMyHome(MarkerIconBase):
     11     distanceFadeAlphaNearFar = None
     12     texturePath = homestation.texture.icon_home_station_16
     13     backgroundColor = homestation.Color.home_station
     14 
     15     def __init__(self, *args, **kwds):
     16         MarkerIconBase.__init__(self, *args, **kwds)
     17         self.stationInfo = kwds['stationInfo']
     18         self.typeID = self.stationInfo.stationTypeID
     19         self.itemID = self.stationInfo.stationID
     20         self.backgroundGlow = None
     21 
     22     def Load(self):
     23         super(MarkerMyHome, self).Load()
     24         self.backgroundGlow = Sprite(parent=self.markerContainer, align=uiconst.CENTER, state=uiconst.UI_DISABLED, texturePath='res:/UI/Texture/classes/MapView/icon_location_glow.png', color=self.backgroundColor, blendMode=trinity.TR2_SBM_ADDX2, width=102, height=111)
     25 
     26     def SetOverlappedState(self, overlapState):
     27         super(MarkerMyHome, self).SetOverlappedState(overlapState)
     28         if overlapState:
     29             self.backgroundGlow.opacity = 0.0
     30         else:
     31             self.backgroundGlow.opacity = 1.0
     32 
     33     def GetMenu(self):
     34         if self.stationInfo:
     35             return GetMenuService().GetMenuFromItemIDTypeID(self.stationInfo.stationID, self.stationInfo.stationTypeID, noTrace=1)
     36 
     37     def GetLabelText(self):
     38         return GetByLabel('UI/Map/HomeStationLabel')
     39 
     40     def GetDragText(self):
     41         return cfg.evelocations.Get(self.stationInfo.stationID).name
     42 
     43     def GetOverlapSortValue(self, reset = False):
     44         return None