setHome放到web连接
parent
c0e4f8ce94
commit
6feed6a28e
|
|
@ -662,20 +662,6 @@ function M:OnEvtMISSILE(msg)
|
||||||
DispatchEvent(self._dispatcher, GameEvent.MISSILE, nil, msg)
|
DispatchEvent(self._dispatcher, GameEvent.MISSILE, nil, msg)
|
||||||
end
|
end
|
||||||
|
|
||||||
-- 按home建 out在程序外 enter在程序内
|
|
||||||
function M:FG_Set_Home(gameStatus)
|
|
||||||
local _client = ControllerManager.GameNetClinet
|
|
||||||
if not _client then
|
|
||||||
return
|
|
||||||
end
|
|
||||||
local _data = {}
|
|
||||||
_data.uid = DataManager.SelfUser.account_id
|
|
||||||
_data.gameStatus = gameStatus
|
|
||||||
_client:send(Protocol.GAME_SET_HOME, _data, function(res)
|
|
||||||
callback(res)
|
|
||||||
end)
|
|
||||||
end
|
|
||||||
|
|
||||||
function M:DispatchEventTuoGuan(p, isShow, t)
|
function M:DispatchEventTuoGuan(p, isShow, t)
|
||||||
DispatchEvent(self._dispatcher, GameEvent.TupGuanOpen, p, isShow, t)
|
DispatchEvent(self._dispatcher, GameEvent.TupGuanOpen, p, isShow, t)
|
||||||
end
|
end
|
||||||
|
|
|
||||||
|
|
@ -440,6 +440,16 @@ function M:FG_Update_Assistant(groupId, tagId, callback)
|
||||||
end)
|
end)
|
||||||
end
|
end
|
||||||
|
|
||||||
|
-- 按home建 out在程序外 enter在程序内
|
||||||
|
function M:FG_Set_Home(gameStatus)
|
||||||
|
local _data = {}
|
||||||
|
_data.uid = DataManager.SelfUser.account_id
|
||||||
|
_data.gameStatus = gameStatus
|
||||||
|
self._mgr_client:send(Protocol.GAME_SET_HOME, _data, function(res)
|
||||||
|
callback(res)
|
||||||
|
end)
|
||||||
|
end
|
||||||
|
|
||||||
function M:OnEVT_Push_Assistant(evt_data)
|
function M:OnEVT_Push_Assistant(evt_data)
|
||||||
print("收到助理刷新推送")
|
print("收到助理刷新推送")
|
||||||
pt(evt_data)
|
pt(evt_data)
|
||||||
|
|
|
||||||
|
|
@ -63,16 +63,10 @@ function FamilyAuditNumber:Show(group)
|
||||||
end
|
end
|
||||||
end)
|
end)
|
||||||
|
|
||||||
local mgr_ctr = ControllerManager.GetController(GroupMgrController)
|
|
||||||
mgr_ctr:AddEventListener(GroupMgrEvent.OnNewApply, handler(self, self.OnNewApply))
|
|
||||||
|
|
||||||
BaseView.Show(self)
|
BaseView.Show(self)
|
||||||
end
|
end
|
||||||
|
|
||||||
function FamilyAuditNumber:Close()
|
function FamilyAuditNumber:Close()
|
||||||
local mgr_ctr = ControllerManager.GetController(GroupMgrController)
|
|
||||||
mgr_ctr:RemoveEventListener(GroupMgrEvent.OnNewApply, handler(self, self.OnNewApply))
|
|
||||||
|
|
||||||
BaseView.Close(self)
|
BaseView.Close(self)
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -301,9 +301,9 @@ function OnApplicationPause()
|
||||||
-- ViewUtil.CloseModalWait()
|
-- ViewUtil.CloseModalWait()
|
||||||
ViewManager.OnApplicationPause()
|
ViewManager.OnApplicationPause()
|
||||||
|
|
||||||
local _gamectr = ControllerManager.GetController(GameController)
|
local gMgr = ControllerManager.GetController(GroupMgrController)
|
||||||
if _gamectr then
|
if gMgr then
|
||||||
_gamectr:FG_Set_Home("out")
|
gMgr:FG_Set_Home("out")
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
@ -311,9 +311,9 @@ end
|
||||||
function OnApplicationActive()
|
function OnApplicationActive()
|
||||||
ViewManager.OnApplicationActive()
|
ViewManager.OnApplicationActive()
|
||||||
|
|
||||||
local _gamectr = ControllerManager.GetController(GameController)
|
local gMgr = ControllerManager.GetController(GroupMgrController)
|
||||||
if _gamectr then
|
if gMgr then
|
||||||
_gamectr:FG_Set_Home("enter")
|
gMgr:FG_Set_Home("enter")
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue