旁观换背景
parent
a891dfc111
commit
40301d2f4e
|
|
@ -11,15 +11,20 @@ local bg_config = {
|
||||||
local WitnessView = {}
|
local WitnessView = {}
|
||||||
setmetatable(WitnessView, { __index = BaseView })
|
setmetatable(WitnessView, { __index = BaseView })
|
||||||
function WitnessView:init()
|
function WitnessView:init()
|
||||||
self.btn_setting = self._view:GetChild("btn_setting")
|
|
||||||
|
|
||||||
self.btn_setting.onClick:Set(function()
|
|
||||||
local view = MJSettingView.new(self, true)
|
|
||||||
view:Show()
|
|
||||||
end)
|
|
||||||
end
|
end
|
||||||
|
|
||||||
function WitnessView:InitView()
|
function WitnessView:InitView()
|
||||||
|
|
||||||
|
self.btn_setting = self._view:GetChild("btn_setting")
|
||||||
|
|
||||||
|
self.com_logocType = self._view:GetChild("com_logo"):GetController("cType")
|
||||||
|
|
||||||
|
self.btn_setting.onClick:Set(function()
|
||||||
|
local view = MJSettingView.new(self, true)
|
||||||
|
view:Show()
|
||||||
|
end)
|
||||||
|
|
||||||
local default_bg = 1
|
local default_bg = 1
|
||||||
TableBG.LoadTableBG(default_bg, self._room.game_id, self._root_view, bg_config)
|
TableBG.LoadTableBG(default_bg, self._room.game_id, self._root_view, bg_config)
|
||||||
end
|
end
|
||||||
|
|
|
||||||
|
|
@ -111,6 +111,7 @@ function M:InitView(url)
|
||||||
-------------------------------------------------------
|
-------------------------------------------------------
|
||||||
|
|
||||||
self._ctr_state.selectedIndex = 4
|
self._ctr_state.selectedIndex = 4
|
||||||
|
self.com_logocType.selectedIndex = 0
|
||||||
end
|
end
|
||||||
|
|
||||||
function M:EventInit()
|
function M:EventInit()
|
||||||
|
|
|
||||||
|
|
@ -110,6 +110,7 @@ function M:InitView(url)
|
||||||
-------------------------------------------------------
|
-------------------------------------------------------
|
||||||
|
|
||||||
self._ctr_state.selectedIndex = 4
|
self._ctr_state.selectedIndex = 4
|
||||||
|
self.com_logocType.selectedIndex = 3
|
||||||
end
|
end
|
||||||
|
|
||||||
function M:EventInit()
|
function M:EventInit()
|
||||||
|
|
|
||||||
|
|
@ -132,13 +132,10 @@ function M:InitView(url)
|
||||||
end)
|
end)
|
||||||
end
|
end
|
||||||
|
|
||||||
self._view:GetChild('btn_setting').onClick:Add(handler(self, function()
|
|
||||||
local settingView = SettingView.new(self, 1)
|
|
||||||
settingView:Show()
|
|
||||||
end))
|
|
||||||
-------------------------------------------------------
|
-------------------------------------------------------
|
||||||
|
|
||||||
self._ctr_state.selectedIndex = 4
|
self._ctr_state.selectedIndex = 4
|
||||||
|
self.com_logocType.selectedIndex = 2
|
||||||
end
|
end
|
||||||
|
|
||||||
function M:EventInit()
|
function M:EventInit()
|
||||||
|
|
|
||||||
|
|
@ -110,6 +110,7 @@ function M:InitView(url)
|
||||||
-------------------------------------------------------
|
-------------------------------------------------------
|
||||||
|
|
||||||
self._ctr_state.selectedIndex = 4
|
self._ctr_state.selectedIndex = 4
|
||||||
|
self.com_logocType.selectedIndex = 1
|
||||||
end
|
end
|
||||||
|
|
||||||
function M:EventInit()
|
function M:EventInit()
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue