#pragma once #include "KUIDefine.h" #include "KUIGenWnd.h" #include "KUIWndManager.h" #include "GameType.h" class CPartyListMgr; struct SGameMessage; class SGameManager; typedef std::vector< struct AddOnWndOpenClose* > AddOnWndList; typedef std::vector< struct AddOnWndOpenClose* >::iterator iter_AddonWndList; struct AddOnWndOpenClose { int click_mode; int window_id; KUIWnd* addonwnd; int addon_posx_type; int addon_posy_type; int pos_x; int pos_y; std::vector< std::string > vControl_list; const bool operator == ( const int& rhs ) const { return ( this->window_id == rhs ); } AddOnWndOpenClose( int _window_id, KUIWnd* wnd, int _click_mode, std::vector< std::string >& control_list, int _addon_posx_type, int _addon_posy_type, int _pos_x, int _pos_y ) : window_id( _window_id ), click_mode( _click_mode ), addonwnd( wnd ) , addon_posx_type( _addon_posx_type ) , addon_posy_type( _addon_posy_type ) , pos_x( _pos_x ) , pos_y( _pos_y ) { std::vector< std::string >::iterator it = control_list.begin(); while( it != control_list.end() ) { vControl_list.push_back( (*it).c_str() ); ++it; } } ~AddOnWndOpenClose() { addonwnd = NULL; vControl_list.clear(); } }; class SUIWnd : public KUIGenWnd { public: SUIWnd( class SGameManager* pGameManager ); virtual ~SUIWnd(); public: virtual void ProcMsgAtStatic( SGameMessage* pMsg ) { }; virtual SUIWnd* CreateWnd( const char* szNUIFileName, KUIWndManager* pWndManager, KPoint kPos, int nWindowID = -1 ); virtual bool InitControls( KPoint kPos ); virtual bool InitData( bool bReload = false ); void LimitMoveWnd( int nLeft = 0, int nTop = 0, int nRight = 0, int nBottom = 0 ); virtual void OnNotifyUIWindowOpen( bool bOpen, bool bLimitWnd = true ); virtual void OnRefresh( SGameMessage* pMsg ) {}; virtual void SetWindowID( int nWindowID ) { m_nWindowID = nWindowID; }; virtual int GetGenWndID() { return m_nWindowID; }; void SetDynamicID( int nDynamicWndID ); virtual void PumpUpMessage( LPCSTR lpszControlID, DWORD nMessage, DWORD lparam, DWORD wparam ); virtual DWORD OnMouseMessage(DWORD dwMessage, int x, int y); void AddChildAddonWnd( int window_id, KUIWnd *wnd, int click_mode, std::vector< std::string >& control_list, int addon_posx_type, int addon_posy_type, int pos_x, int pos_y ); bool RemoveChildAddonWnd( int window_id, KUIWnd *wnd ); AddOnWndOpenClose* GetAddOnWnd( int window_id ); bool SetAddOnWindowPosition( AddOnWndOpenClose* pInfo, KUIWnd* pMainWnd, int mouse_posx, int mouse_posy ); // bintitle. 2010.04.30. // 자식컨트롤의 Caption 텍스트가 컨트롤의 크기를 넘어설경우 // Caption 텍스트를 컨트롤의 크기에 맞게 자르고( 맨끝 .. 처리 ), // 원본텍스트는 툴팁으로 뜨게 한다. void CutCaptionNTooltip(); void SetUseCutCaption(){ m_bCutCaption = true; } // 2011.10.31 : servantes : SPartyMgr 관리 클래스 CPartyListMgr* GetPartyListMgrPtr() { return &m_PartyMgr; } SGameManager* GetGameManager() { return m_pGameManager; } bool IsAlt() { return m_bAltKey; } protected: bool m_bShiftKey; // Moved to the parent class because it is frequently used in the subclasses bool m_bControlKey; // Moved to the parent class because it is frequently used in the subclasses bool m_bAltKey; SGameManager* m_pGameManager; int m_nWindowID; int m_nDynamicWndID; bool m_bCutCaption; // Caption 텍스트 자르기. AddOnWndList m_listChildAddonWnd; class SRaidMgr& m_RaidMgr; class CPartyListMgr& m_PartyMgr; class SGuildMgr& m_GuildMgr; class SFriendMgr& m_FriendMgr; class SCutMgr& m_CutMgr; class STradeMgr& m_TradeMgr; class SStorageMgr& m_StorageMgr; class SMotionMgr& m_MotionMgr; class SPlayerInfoMgr& m_PlayerInfoMgr; class SInventoryMgr& m_InventoryMgr; class SCreatureSlotMgr& m_CreatureSlotMgr; class SSkillSlotMgr& m_SkillSlotMgr; class SCreatureSkillSlotMgr& m_CreatureSkillSlotMgr; class SPetMgr& m_PetMgr; // sonador #2.1.2.4.3 팻 조작 UI 연동 class SSkillSlotMgr& m_PetSkillMgr; // sonador #2.1.2.4.3 팻 조작 UI 연동 class SGuildDataMgr& m_GuildDataMgr; class STitleMgr& m_TitleMgr; };