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

util.py (1236B)


      1 #Embedded file name: C:\BuildAgent\work\20d73f1b24eed06e\eve\release\V24.01\eve\client\script\ui\shared\theatersOfWar\util.py
      2 from eve.client.script.ui.shared.theatersOfWar.dashboard.dashboardConst import ID_FW, ID_ENLISTMENT, ID_INSURGENCY, ID_CAMPAIGNS
      3 
      4 def open_fw_window(faction_id = None, system_id = None, tab_id = None, *kwargs):
      5     wnd = _open_theater_of_wars_window_on_panel(ID_FW)
      6     wnd.select_fw_panel(faction_id, system_id, forceExpanded=True, tab_id=tab_id)
      7     return wnd
      8 
      9 
     10 def open_insurgencies_window():
     11     wnd = _open_theater_of_wars_window_on_panel(ID_INSURGENCY)
     12     wnd.select_panel(ID_INSURGENCY)
     13 
     14 
     15 def open_enlistment_window():
     16     wnd = _open_theater_of_wars_window_on_panel(ID_ENLISTMENT)
     17     wnd.select_panel(ID_ENLISTMENT)
     18 
     19 
     20 def open_campaigns():
     21     wnd = _open_theater_of_wars_window_on_panel(ID_CAMPAIGNS)
     22     wnd.select_panel(ID_CAMPAIGNS)
     23 
     24 
     25 def _open_theater_of_wars_window_on_panel(panel_id):
     26     from eve.client.script.ui.shared.theatersOfWar.dashboard.dashboard import TheatersOfWarDashboardWnd
     27     wnd = TheatersOfWarDashboardWnd.GetIfOpen()
     28     if wnd and not wnd.destroyed:
     29         wnd.Maximize()
     30     else:
     31         wnd = TheatersOfWarDashboardWnd.Open(selected_panel_id=panel_id)
     32     return wnd