<!--
/*
看完功夫回到家，发现反映冷冷淡淡的，突然没什么性质继续写这个了。。。本来打算Alpha 3是改进巧嘴的。。现在无限期推延。。阿门。。。。
使用或修改代码者请保留此段和关于信息
*/
var ie4=document.all&&navigator.userAgent.indexOf("Opera")==-1
var ns6=document.getElementById&&!document.all
var ns4=document.layers
document.write("<style type=text/css>.Xnc_Btn{Text-align: center;cursor: pointer;HEIGHT: 31px;WIDTH: 31px;}.Xnc_BtnMouseOverUp{border : 1px solid #3169C6;background-color : #C6D3EF;Text-align: center;cursor: pointer;HEIGHT: 31px;WIDTH: 31px;}</style>")

var EmotPage,AuPage,Board_Setting79;
var Board_Setting79 =1;

var Audibles_List = "ylei_mfqq/xnc/|||就这事啊！地球人都知道|||嘿嘿！逗你玩！|||年轻人，做人要厚道！|||这干嘛？这不是那我打岔吗？|||一定要幸福喔！|||你好可爱耶！|||加油喔！|||我好想你喔 ~|||你不要这样嘛|||真的好感激你啊|||你简直太让我感动了！|||过来..近点...再近点...Kiss！|||强！实在是强！|||真真的么？我要晕了！|||最近真的好想你哦！|||啊你是中邪喔..|||你好讨厌喔~|||抽根菸吧！|||不干不干就是不干！|||饿不饿我请你吃饭|||听见了吗那是我肚子在叫|||哼！小样！我看你还真是找扁！|||坦白从宽，你就交代了吧！|||哼！你这骗子|||我就是喜欢你动作非常慢的时候...|||Hi!是你吧，我知道你在，我可看见你了！|||哎~~看来你真的很寂寞！|||年轻人虚心点没错|||这么说你还不明白，你猪头啊！|||掰掰啰！|||拜拜了您那|||哎呦！老板来了，我先走了啊！|||不行不行！我得上厕所...得上厕所！|||晚安做个好梦！|||我困得不行了得先走一步了|||有人在家吗？|||开会啰！|||早安！|||还在加班？真忙假忙啊？|||你可算来了，我等你很久了！|||来啦小妞|||早上好，您来啦！|||你要死啦～到现在才出现，到哪里潜水去啦...|||喂..我老板来了，先闪一下喽~下次再聊..|||啊～～～这是一定要的啦！|||嗯哼～人家.. 去撇个尿啰..嗯哼～|||嗯哼～来，亲一个~|||起来动一动吧，follow me! one more, two more…|||祝你生日快乐~祝你生日快乐..喔喔！祝你生日快乐喽|||不知道该说什么 ..|||好想睡喔...zzz|||让我想一想~~"
var Audibles_Text = Audibles_List.split("|||");
var AuCountLength   = Audibles_Text.length-1;
var AuPage_Size     = 10;
var AuPage_Max      = AuCountLength/AuPage_Size;
if ((AuCountLength % AuPage_Size)>0){
	AuPage_Max = Math.floor(AuPage_Max+1);
}
function DispAudibles(Obj,AuID) {
	Obj.children[0].Play();
	Obj.title = Audibles_Text[AuID];
}

var NowMeID;

function Show_Xnc_Audibles(Page) {
	if(!Board_Setting79){
		alert("页面尚未载入完毕！");
	}else{
		if(Board_Setting79!="1"){
			alert("本版禁止使用巧嘴娃娃！");
		}else{
			if (AuPage&&Page==0){Page=AuPage;}
			if(Page==0){Page=1}

				AuPage = Page;
				var ShowPage = 0;
				var ShowList = '';

				for (i = Page * AuPage_Size - AuPage_Size + 1;i <= (Page * AuPage_Size);i++){
					if (i <= AuCountLength){
						Audibles_ID = "00" + i;
						Audibles_ID = Audibles_ID.substr(Audibles_ID.length-2,2)
						Audibles_Url = 'ylei_mfqq/xnc/'+Audibles_ID + '.Swf'
						ShowList = ShowList + '<TD nowrap><Div style="padding:0;position:relative;width:48;height:48;left:0;top:0;"><Div style="padding:0;position:absolute;width:48;height:48;left:0;top:0;z-index:1;"><OBJECT codeBase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=4,0,2,0" classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" width="48" height="48" Id="Audible' + Audibles_ID +'"><PARAM NAME=movie VALUE="'+ Audibles_Url +'"><param name=menu value=false><PARAM NAME=quality VALUE=high><PARAM NAME=play VALUE=false><param name="wmode" value="transparent"><embed src="' + Audibles_Url +'" quality="high" pluginspage="http://www.macromedia.com/shockwave/download/index.cgi?P1_Prod_Version=ShockwaveFlash" type="application/x-shockwave-flash" width="48" height="48"></embed></OBJECT></Div><img src="ylei_mfqq/blank.gif" style="padding:0;position:absolute;width:48;height:48;left:0;top:0;z-index:2;cursor:hand;" onmouseover="this.parentElement.children[0].children[0].Play();this.title = Audibles_Text['+i+']"  onClick="putEmot(\'Ylei_Au'+Audibles_ID+'\')"></Div></TD>'
						ShowPage = ShowPage + 1
					}
				}
						ShowList = ShowList + '<TD width="100%"><\/TD>'
						ShowPage = ShowPage + 1
				if(Page > 1){
						ShowList = '<TD width="10" Style="border: 1px #999999 solid;cursor:hand; background-color:#CCCCCC;line-height: 8px;font-family: Webdings;" onclick="Show_Xnc_Audibles('+(Page-1)+');" title="前' + AuPage_Size + '个娃娃" onmouseover="this.style.background=\'#C6D3EF\';this.style.border=\'1px #3169C6 solid\'" onmouseout="this.style.background=\'#CCCCCC\';this.style.border=\'1px #999999 solid\'">3</TD>' + ShowList
						ShowPage = ShowPage + 1
				}

				if(Page < AuPage_Max){
						ShowList = ShowList + '<TD width="10" Style="border: 1px #999999 solid;cursor:hand; background-color:#CCCCCC;line-height: 8px;font-family: Webdings;" title="后' + AuPage_Size + '个娃娃" onclick="Show_Xnc_Audibles('+(Page+1)+');" onmouseover="this.style.background=\'#C6D3EF\';this.style.border=\'1px #3169C6 solid\'" onmouseout="this.style.background=\'#CCCCCC\';this.style.border=\'1px #999999 solid\'">4</TD>'
						ShowPage = ShowPage + 1
				}

				ShowList = '<table width="100%" height="60" border="0" cellspacing="1" cellpadding="1" Onselectstart="return false" oncontextmenu=self.event.returnValue=false><TR>' + ShowList + '<\/TR><\/TR><\/table>'


				document.getElementById("emot").innerHTML = ShowList;
				Xnc_SetBtnMode(2);
		}
	}
}


/******************************************************************************
* MagicEmot functions.                                                        *
******************************************************************************/
document.write('<Div id="Xnc_Emot" Style="POSITION:absolute;Z-INDEX: 99;"></Div>');
document.write('<script type="text/javascript" src="ylei_mfqq/qqclass.js"><\/script>');

function DispMagicEmot(EmotID){
	MagicEmotUrl = "ylei_mfqq/swf/" + EmotID + ".swf";
	var obj = document.getElementById("Xnc_Emot");
		obj.innerHTML = '<Div style="padding:0;position:relative;"><Div style="padding:0;position:absolute;z-index:1;"><OBJECT codeBase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=4,0,2,0" classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" width="400" height="300"><PARAM NAME=movie VALUE="'+ MagicEmotUrl +'"><PARAM NAME=quality VALUE=high><PARAM NAME=play VALUE=true><param name="wmode" value="transparent"><embed src="' + MagicEmotUrl +'" wmode="transparent" quality="high" pluginspage="http://www.macromedia.com/shockwave/download/index.cgi?P1_Prod_Version=ShockwaveFlash" type="application/x-shockwave-flash" width="400" height="300"></embed></OBJECT></Div><img src="ylei_mfqq/blank.gif" style="padding:0;position:absolute;width:400;height:300;left:0;top:0;z-index:2;cursor:hand;" Onclick="document.getElementById(\'Xnc_Emot\').innerHTML=\'\';" Alt="点击隐藏魔法表情"  oncontextmenu="false"></Div>';
		obj.style.top = (document.body.scrollTop+((document.body.clientHeight-300)/2))+"px";
		obj.style.left = (document.body.scrollLeft+((document.body.clientWidth-400)/2))+"px";
		obj.style.display = 'inline';
	EmotID += Math.random();
	window.setTimeout('HideMagicEmot('+EmotID+')',8000);
	NowMeID = EmotID;
}

function HideMagicEmot(EmotID) {
	if(NowMeID == EmotID) {
		document.getElementById("Xnc_Emot").style.display = 'none';
		NowMeID = '';
	}
}

var MePage_Size			= 12;

//选择魔法表情
function Show_Xnc_MagicEmot(Page,Mode) {
	if(!Board_Setting79){
		alert("页面尚未载入完毕！");
	}else{
		if(Board_Setting79!="1"){
			alert("本版禁止使用魔法传情！");
		}else{

		if(!Mode&&Mode!=0) { Mode=1;}
		var MeItemCount			= Xnc_MagicEmot_ID[Mode].length-1;
		var MePage_Max			= MeItemCount/MePage_Size;
		
		if ((MeItemCount % MePage_Size)>0){MePage_Max = Math.floor(MePage_Max+1);}
			//if (MagicPage&&Page==0){Page=MagicPage;}
			if(Page==0){Page=1}

			MagicPage = Page;
			var ShowList = '';
			for (i = Page * MePage_Size - MePage_Size + 1;i <= (Page * MePage_Size);i++){
				if (i <= MeItemCount){
						ShowList = ShowList + '<img src="ylei_mfqq/gif/' + Xnc_MagicEmot_ID[Mode][i] + '.gif" border="0" oncontextmenu="DispMagicEmot(\'' + Xnc_MagicEmot_ID[Mode][i] + '\');" Onclick="_inputMagicEmot(' + Xnc_MagicEmot_ID[Mode][i] + ',\'' + Xnc_MagicEmot_Info[Mode][i] + '\');" style="cursor: hand;border:2px solid #666666;margin:1px 0 0 1px" title="' + Xnc_MagicEmot_Info[Mode][i] + '">';
				}
			}

			ShowList = '<table width="100%" height="60" border="0" cellspacing="1" cellpadding="1" Onselectstart="return false" oncontextmenu=self.event.returnValue=false><TR><TH height="22">' + Show_Xnc_MagicEmot_Class(Mode) + '<\/TH><\/TR><TR><TD>' + ShowList + '<\/TD><\/TR><TR><TD>&nbsp;<img src="ylei_mfqq/info.gif" onclick="Show_About()" align="middle" Style="cursor: pointer;" title="信息"> [<font color="red">左键插入，右键播放</font>] ' + Xnc_PageJump('魔法表情',Xnc_MagicEmot_Class[Mode],'Show_Xnc_MagicEmot',MeItemCount,Page,MePage_Max,Mode) + '<\/TD><\/TR><\/table>';

			document.getElementById("emot").innerHTML = ShowList;
			Xnc_SetBtnMode(3);
		}
	}
}

function Show_Xnc_MagicEmot_Class(Mode) {
	var Classlist ='';
	
		for (i = 1;i <= MeClassCount;i++){
				if (i == Mode) {
					Classlist += '[ ' + Xnc_MagicEmot_Class[i] +' ] | ';
				}else{
					Classlist += '<A href="javascript:Show_Xnc_MagicEmot(1,' + i +')">'+Xnc_MagicEmot_Class[i] + '</A> | ';
				}
		}
		if (Mode == 0) {
			Classlist += '[ ' + Xnc_MagicEmot_Class[0] +' ]';
		}else{
			Classlist += '<A href="javascript:Show_Xnc_MagicEmot(1,' + 0 +')">'+Xnc_MagicEmot_Class[0] + '</A>';
		}
		return Classlist
}

//插入并累加到Cookie,创建常用类
function _inputMagicEmot(nID,sText){
	nIdCount = 12;	//设定常用类的数目
	sTlist   = Xnc_MagicEmot_ID[0].toString(0)+',';
	if(sTlist.indexOf(','+nID+',')== -1){
		sIDlist ='|'+ nID;
		ssaylist = '|' + sText;
	for (i = 1;i < nIdCount;i++){
		if(Xnc_MagicEmot_ID[0][i]){
			sIDlist += '|' + Xnc_MagicEmot_ID[0][i];
			ssaylist += '|' + Xnc_MagicEmot_Info[0][i];
		}
	}
	Xnc_MagicEmot_ID[0] = sIDlist.split("|");
	Xnc_MagicEmot_Info[0] =ssaylist.split("|");
	SetCookie("MagicEmot_ID",sIDlist);
	SetCookie("MagicEmot_Info",ssaylist);
	}
	putEmot('Magic' + nID);
}


/******************************************************************************
* End of MagicEmot functions.                                                 *
******************************************************************************/



/*心情图片*/


function Show_Xnc_Emot(Page) {
	Xnc_SetBtnMode(1);
	ShowForum_Emot(1);
}

/******************************************************************************
* Share functions.                                                           *
******************************************************************************/


//分页处理
function Xnc_PageJump(Typename,ClassType,Act,ItemCount,Page,MaxPage,Mode) {
	var PageList ='';
	if(Page > 1) {
		PageList = 	' <A href="javascript:' + Act+'(1,' + Mode + ')">1<\/A>';
	}

		if((Page-5)>1){
			PageList += '..'
			PageList += 	' <A href="javascript:' + Act+'(' + (Page-4) + ',' + Mode + ')">' + (Page-4) + '<\/A>';
			PageList += 	' <A href="javascript:' + Act+'(' + (Page-3) + ',' + Mode + ')">' + (Page-3) + '<\/A>';
			PageList += 	' <A href="javascript:' + Act+'(' + (Page-2) + ',' + Mode + ')">' + (Page-2) + '<\/A>';
			PageList += 	' <A href="javascript:' + Act+'(' + (Page-1) + ',' + Mode + ')">' + (Page-1) + '<\/A>';
		}else{
			for (i = 2;i < Page;i++){
				PageList += 	' <A href="javascript:' + Act+'(' + i + ',' + Mode + ')">' + i + '<\/A>';
			}
		}
		PageList += ' [<B>'+Page+'</B>]';
		if((MaxPage-4)>Page){
			PageList += 	' <A href="javascript:' + Act+'(' + (Page+1) + ',' + Mode + ')">' + (Page+1) + '<\/A>';
			PageList += 	' <A href="javascript:' + Act+'(' + (Page+2) + ',' + Mode + ')">' + (Page+2) + '<\/A>';
			PageList += 	' <A href="javascript:' + Act+'(' + (Page+3) + ',' + Mode + ')">' + (Page+3) + '<\/A>';
			PageList += '..'
		}else{
			for (i = (Page+1);i < MaxPage;i++){
				PageList += 	' <A href="javascript:' + Act+'(' + i + ',' + Mode + ')">' + i + '<\/A>';
			}
		}

	if(Page < MaxPage) {
		PageList += 	' <A href="javascript:' + Act +'(' +  MaxPage + ',' + Mode + ')">' + MaxPage + '<\/A>'
	}

	return ClassType + '类共 ' + ItemCount + ' 个' + Typename + '，分页：'+PageList;
}

function Xnc_PageList(Typename,Act,ItemCount,Page,MaxPage) {
	var PageList ='';
	if(Page > 1) {
		PageList = 	' <A href="javascript:' + Act+'(1)">1<\/A>';
	}

		if((Page-4)>1){
			PageList += '..'
			PageList += 	' <A href="javascript:' + Act+'(' + (Page-3) + ')">' + (Page-3) + '<\/A>';
			PageList += 	' <A href="javascript:' + Act+'(' + (Page-2) + ')">' + (Page-2) + '<\/A>';
			PageList += 	' <A href="javascript:' + Act+'(' + (Page-1) + ')">' + (Page-1) + '<\/A>';
		}else{
			for (i = 2;i < Page;i++){
				PageList += 	' <A href="javascript:' + Act+'(' + i + ')">' + i + '<\/A>';
			}
		}
		PageList += ' [<B>'+Page+'</B>]';
		if((MaxPage-5)>Page){
			PageList += 	' <A href="javascript:' + Act+'(' + (Page+1) + ')">' + (Page+1) + '<\/A>';
			PageList += 	' <A href="javascript:' + Act+'(' + (Page+2) + ')">' + (Page+2) + '<\/A>';
			PageList += 	' <A href="javascript:' + Act+'(' + (Page+3) + ')">' + (Page+3) + '<\/A>';
			PageList += 	' <A href="javascript:' + Act+'(' + (Page+4) + ')">' + (Page+4) + '<\/A>';
			PageList += '..'
		}else{
			for (i = (Page+1);i < MaxPage;i++){
				PageList += 	' <A href="javascript:' + Act+'(' + i + ')">' + i + '<\/A>';
			}
		}

	if(Page < MaxPage) {
		PageList += 	' <A href="javascript:' + Act +'(' +  MaxPage + ')">' + MaxPage + '<\/A>'
	}

	return '共' + ItemCount + '个' + Typename + '，分页：'+PageList;
}

/*初始化*/
function Xnc_Emot_init() {
		Xnc_SetBtnMode(2);
}

/*按钮样式控制*/
function Xnc_SetBtnMode(Mode){
	var EmBtn = document.getElementById("SetEm");
	var AuBtn = document.getElementById("SetAu");
	var MeBtn = document.getElementById("SetMe");

		switch(Mode) {
			case 1 :
				EmBtn.className="Xnc_BtnMouseOverUp";
				AuBtn.className="Xnc_Btn";
				MeBtn.className="Xnc_Btn";
				break;
			case 2 :
				EmBtn.className="Xnc_Btn";
				AuBtn.className="Xnc_BtnMouseOverUp";
				MeBtn.className="Xnc_Btn";
				break;
			case 3 :
				EmBtn.className="Xnc_Btn";
				AuBtn.className="Xnc_Btn";
				MeBtn.className="Xnc_BtnMouseOverUp";
				break;
		}
}

function putEmot(NewCode) {
	NewCode="["+NewCode+"]";
        document.all ? qqinsertAtCaret(document.input.message, NewCode) : document.input.message.value += NewCode;
       	setfocus();
}
function qqinsertAtCaret (textEl, text){
        if (textEl.createTextRange && textEl.caretPos){
                var caretPos = textEl.caretPos;
                caretPos.text += caretPos.text.charAt(caretPos.text.length - 2) == ' ' ? text + ' ' : text;
        } else if(textEl) {
                textEl.value += text;
        } else {
        	textEl.value = text;
        }
}
//请勿修改删除此信息；
function Show_About(){
	alert("Flash Emot 2.5 Alpha 2\n\n Write: NoGoD\n  Build: 20041227\nCount: " + AuCountLength + " Audibles; " + MeCountLength + "/"+ MeClassCount + " MagicEmots.\n\nHappy Christmas!\n\n");
}

/******************************************************************************
* Cookie functions.                                                           *
******************************************************************************/
function SetCookie(sName, sValue){
	document.cookie = "Xnc_Emot" + sName + "=" + escape(sValue) + "; path=/; expires=Sun, 25 Oct 2099 23:59:59 UTC;";
}

function GetCookie(name) {
  var search;

  search = "Xnc_Emot" + name + "=";
  offset = document.cookie.indexOf(search) ;
  if (offset != -1) {
    offset += search.length ;
    end = document.cookie.indexOf(";", offset) ;
    if (end == -1)
      end = document.cookie.length;
    return unescape(document.cookie.substring(offset, end));
  }
  else
    return "";
}

function deleteCookie(name) {
	setCookie(name, "");
}



/******************************************************************************
* End of cookie functions.                                                    *
******************************************************************************/
-->