function Channel()
{
	var m_initialized = false;
	
	this.initialize = function()
		{
			m_initialized = true;
		}
	
	this.display = function()
		{
			if(!m_initialized)
			{
				this.getChannel();	
				m_initialized = true;
			}
			_console.lastReloadComponent = this;
		}
	this.getChannel = function(cid, pn)
		{
			var args = new Object();
			
			var ps = 7; //page size
			
			if(Console.MODE_LARGE==_console.m_consoleMode)
			{
				args.ptrs = ProgramList.PAGESIZE_THUMB_ROWSIZE_LARGE;
				args.large = true;
				//ps = ProgramList.PAGESIZE_THUMB_LARGE;
			}
			else
			{
				args.ptrs = ProgramList.PAGESIZE_THUMB_ROWSIZE;
				//ps = ProgramList.PAGESIZE_THUMB;
			}
			
			if(pn == null)
			{
				args.ispaging = "false";
				pn = 1;
			}
			else
			{
				args.ispaging = "true";
			}

			args.cid = cid;
			args.pn = pn;
			args.ps = ps;
			
			args.channeldays = 7; //keep it >1 to compatible with JAVA code.
			args.menuChannelIndex = g_lastChannelIndex;
			args.menuChannelId = g_lastChannelId;

			document.getElementById("content_Channel").innerHTML = getLocalizedString("loading");
			_console.getComponentContent("guide", args, this.getChannelCallBack);
		}
	this.getChannelCallBack = function(result)
		{
			document.getElementById("content_Channel").innerHTML = result;

			if (g_defaultVideoId!="")
			{	// If deeplinked, don't play first video
				var objVideo = _console.findVideoTbl(g_defaultVideoId, "div_Channel");
				_console.m_lastVideo.objVideo=objVideo;
				_console.selectVideoObj(objVideo);
				_console.populateComingUp();
				g_defaultVideoId="";
			}
			else if (g_firstVideoPlayed==false)
			{
				g_firstVideoPlayed=true;
				var td = document.getElementById("_channel_0");
				if (td)
					td.onclick();
			}
		}
}