Exemplo n.º 1
0
 void Awake()
 {
     m_Instance = this;
     m_TabController.delTabChanged = OnTabChanged;
     if (PlatformHelper.IsChannelTW())
     {
         m_tabSNSWindow.SetActive(true);
     }
 }
Exemplo n.º 2
0
    public void OnTabClicked(TabButton curTab)
    {
        if (!m_bEnableClick)
        {
            return;
        }

        if (curHighLightTab == curTab)
        {
            #region
            //策划需求双击主界面上任务界面的任务按钮和组队按钮,分别打开任务界面和组队界面。
            if (curTab != null)
            {
                switch (curTab.name)
                {
                case "Tab1-Mission":
                    MissionLogLogic.IsOpenFromMissionDialog = true;
                    if (PlayerFrameLogic.Instance() != null)
                    {
                        PlayerFrameLogic.Instance().PlayerFrameHeadOnClick();
                    }
                    UIManager.ShowUI(UIInfo.MissionLogRoot);
                    break;

                case "Tab2-Team":
                    RelationLogic.m_OpenWay = RelationLogic.OPEN_WAY.MISSION_TEAM;
                    if (GameManager.gameManager.PlayerDataPool.TeamInfo != null && Games.GlobeDefine.GlobeVar.INVALID_ID != GameManager.gameManager.PlayerDataPool.TeamInfo.TeamID)
                    {
                        RelationLogic.OpenTeamWindow(RelationTeamWindow.TeamTab.TeamTab_TeamInfo);
                    }
                    else
                    {
                        RelationLogic.OpenTeamWindow(RelationTeamWindow.TeamTab.TeamTab_NearTeam);
                    }
                    break;

                default:
                    break;
                }
            }
            #endregion
            return;
        }
        if (RelationFriendWindow.Instance() != null && RelationFriendWindow.Instance().m_OtherWindows.activeSelf)
        {
            RelationFriendWindow.Instance().m_OtherWindows.SetActive(false);
        }
        DoChangeTab(curTab);
    }
Exemplo n.º 3
0
 public void toggltDelGuid()
 {
     if (GlobeVar.INVALID_GUID != m_Guid)
     {
         if (m_toggleBtn.value == true)
         {
             RelationFriendWindow.Instance().recordHateFriendGuid(m_Guid);
         }
         else
         {
             RelationFriendWindow.Instance().removeDelHateGuid(m_Guid);
             //_showBtnByType();
         }
     }
 }
Exemplo n.º 4
0
        public uint Execute(PacketDistributed ipacket)
        {
            GC_RET_TRAIL packet = (GC_RET_TRAIL)ipacket;

            if (null == packet)
            {
                return((uint)PACKET_EXE.PACKET_EXE_ERROR);
            }
            //enter your logic
            if (RelationFriendWindow.Instance() != null)
            {
                RelationFriendWindow.Instance().HandleRetTrail(packet.SceneClass, packet.SceneInst, packet.PosX, packet.PosZ);
            }
            return((uint)PACKET_EXE.PACKET_EXE_CONTINUE);
        }
Exemplo n.º 5
0
 public void onTher()
 {
     OnClickPlayerListItem();
     if (mIsClick == false && m_Guid != GlobeVar.INVALID_GUID && m_PlayerName != "")
     {
         if (RelationFriendWindow.Instance() != null)
         {
             RelationFriendWindow.Instance().showOtherWin(m_Guid, m_PlayerName);
         }
         mIsClick = true;
     }
     else
     {
         if (RelationFriendWindow.Instance() != null)
         {
             RelationFriendWindow.Instance().hideOtherWindows();
         }
         mIsClick = false;
     }
 }
Exemplo n.º 6
0
 void OnDestroy()
 {
     m_Instance = null;
 }
Exemplo n.º 7
0
    public static PlayerListItemLogic CreateItem(GameObject grid, GameObject resItem, string name, RelationFriendWindow parent)
    {
        if (null == resItem)
        {
            LogModule.ErrorLog("PlayerListItemLogic Create resItem is null_1");
            return(null);
        }

        GameObject curItem = Utils.BindObjToParent(resItem, grid, name);

        if (null != curItem)
        {
            PlayerListItemLogic curItemComponent = curItem.GetComponent <PlayerListItemLogic>();
            if (null != curItemComponent)
            {
                curItemComponent.SetParent(parent);
            }

            return(curItemComponent);
        }

        return(null);
    }
Exemplo n.º 8
0
 public void SetParent(RelationTeamWindow parent)
 {
     m_TeamParent   = parent;
     m_FriendParent = null;
 }