function module.new(z)local w=setmetatable({},methods)local l,b,e,u,g,s,G=CreateGuiObjects()w.GuiObject=l w.NameTag=b w.NameTagNonSelect=e w.NameTagSelect=u w.NewMessageIcon=g w.UnselectedFrame=s w.SelectedFrame=G w.BlueBarLeft=G.BlueBarLeft w.BlueBarRight=G.BlueBarRight w.BackgroundImage=G.BackgroundImage w.WhiteTextNewMessageNotification=w.NewMessageIcon.TextLabel w.ChannelName=z w.UnreadMessageCount=0 w.Active=false w.GuiObject.Name="\070\114\097\109\101\095"..w.ChannelName if string.len(z)>ChatSettings.MaxChannelNameLength then z=string.sub(z,1,ChatSettings.MaxChannelNameLength-3).."\046\046\046"end w.NameTag.Text=""w.NameTagNonSelect.Text=z w.NameTagSelect.Text=z w.AnimParams={}w:InitializeAnimParams()w:AnimGuiObjects()w:SetActive(false)return w end return module
--///////////////////////// Constructors
--//////////////////////////////////////

function module.new(channelName)
	local obj = setmetatable({}, methods)

	local BaseFrame, NameTag, NameTagNonSelect, NameTagSelect, NewMessageIcon, UnselectedFrame, SelectedFrame =
		CreateGuiObjects()
	obj.GuiObject = BaseFrame
	obj.NameTag = NameTag
	obj.NameTagNonSelect = NameTagNonSelect
	obj.NameTagSelect = NameTagSelect
	obj.NewMessageIcon = NewMessageIcon
	obj.UnselectedFrame = UnselectedFrame
	obj.SelectedFrame = SelectedFrame

	obj.BlueBarLeft = SelectedFrame.BlueBarLeft
	obj.BlueBarRight = SelectedFrame.BlueBarRight
	obj.BackgroundImage = SelectedFrame.BackgroundImage
	obj.WhiteTextNewMessageNotification = obj.NewMessageIcon.TextLabel

	obj.ChannelName = channelName
	obj.UnreadMessageCount = 0
	obj.Active = false

	obj.GuiObject.Name = "Frame_" .. obj.ChannelName

	if string.len(channelName) > ChatSettings.MaxChannelNameLength then
		channelName = string.sub(channelName, 1, ChatSettings.MaxChannelNameLength - 3) .. "..."
	end

	--obj.NameTag.Text = channelName

	obj.NameTag.Text = ""
	obj.NameTagNonSelect.Text = channelName
	obj.NameTagSelect.Text = channelName

	obj.AnimParams = {}

	obj:InitializeAnimParams()
	obj:AnimGuiObjects()
	obj:SetActive(false)

	return obj
end

return module
