<!--
/**
 * setting.js
 * @fileoverview 系统设置功能
 * @author Lynk Li
 */

/**
 * @class Setting
 * 系统设置功能,储存一些系统设置常量
 * @constructor
 * @author Lynk Li
 */
function Setting() {
	/**
	 * 界面风格
	 */
	this.style = '0';
	/**
	 * 界面语言
	 */
	this.language = 'scn';
	/**
	 * 基础链接地址
	 */
	this.baseUrl = 'http://web.5107.cn/';
	/**
	 * 图片目录连接地址
	 */
	this.imagesPath = '';
	/**
	 * xml配置文件目录地址
	 */
	this.xmlsPath = '';
	/**
	 * javascript目录连接地址
	 */
	this.jsPath = '';
	/**
	 * 接收服务器消息的Timer的时间间隔
	 */
	this.receiveInteval = 200;
	/**
	 * 界面最小宽度
	 */
	this.minMainWidth = 700;
	/**
	 * 界面的最小高度
	 */
	this.minMainHeight = 500;
	this.setStyle = Setting_setStyle;
	this.setLanguage = Setting_setLanguage;
	/**
	 * 公司ID替换符
	 */
	this.companyCodeReplace = "{#@company#}";
	this.set = Setting_set;
	this.init = Setting_init;
	/**
	 * 基于这些字符串的ID的HTML Object在被点击的时候不清楚页面弹出层，例如id为"left_oplist__dfssdf"的div
	 */
	this.noClearPop = new Array("left_oplist", "left_vlist", "popDiv", "monitor_monitor_list", "viewCols", "chat_functions", "chat_members_list", "monitor_filter");
	/**
	 * 快速体验通道地址
	 */
	this.quickUrl = 'http://cs.5107.cn/v4/other/quickex.php?company=';
	/**
	 * 生成代码获取验证码的URL
	 */
	this.codeKeyUrl = "http://cs.5107.cn/code5/getcode.php?fromwebcl=1";
	/**
	 * 生成代码获取验证码JAVASCRIPT地址
	 */
	this.codeKeyJsUrl = "http://cs.5107.cn/common/securityCode.php?fromwebcl=1";
	/**
	 * 生成代码首页地址
	 */
	this.codeUrl = "http://cs.5107.cn/common/securityCheck.php?fromwebcl=1";
	/**
	 * 统计报表获取验证码的URL
	 */
	this.reportKeyUrl = "http://reports.5107.cn/webreport2007/getcode.php?fromwebcl=1";
	/**
	 * 统计报表获取验证码JAVASCRIPT地址
	 */
	this.reportKeyJsUrl = "http://reports.5107.cn/webreport2007/getcodejs.php?fromwebcl=1";
	/**
	 * 统计报表首页地址
	 */
	this.reportUrl = "http://reports.5107.cn/webreport2007/Stat_glancing.php?fromwebcl=1";
	/**
	 * 上传预存消息的PHP目录地址
	 */
	this.reserveUrl = "http://cs.5107.cn/webcl/php/";
	/**
	 * 预存文件存放目录地址
	 */
	this.reserveBaseUrl = "http://cs.5107.cn/v4/presavefile/";
	/**
	 * mail url
	 */
	this.mailUrl = "http://cs.5107.cn/webcl/php/mail/sendMail.php?";
	/**
	 * 语言包文件名
	 */
	this.languages = new Array("login", "monitor", "personal");
	/**
	 * 默认显示列设置
	 */
	this.defaultShowCols =  _langPackage.setting.defaultShowCols;//"$2#status#状态#1$0#snid#访客#1$10#engineid#搜索引擎#1$11#keyword#关键词#1$13#visitTimes#浏览次数#1$3#request#指定对象#0$4#operator#客服#0$6#area#所在地区#1$7#page#当前页面#1$18#enterTime#进入时间#1$18#stayTime#停留时间#1$19#waitTime#等待时间#0$20#chatTime#对话时间#0$";
	/**
	 * 基础版显示列设置
	 */
	this.baseVersionCols = ["status", "snid", "engineid", "keyword", "request", "operator", "area", "page"];
	/**
	 * 右下角弹出提示框 每次上升/下降的像素
	 */
	this.popupIntervalHeight = 10;//每次上升/下降的像素
	/**
	 * 右下角弹出提示框的宽度
	 */
	this.popupWidth = 185;//popupIntervalHeight*N
	/**
	 * 右下角弹出提示框的高度 
	 */
	this.popupHeight = 121;//popupIntervalHeight*N
	/**
	 * 右下角弹出提示框的渐变间隔，毫秒 
	 */
	this.popupInterval = 50;//渐变间隔，毫秒
	/**
	 * 右下角弹出提示框 停留时间，毫秒，设置为popupInterval的整数倍
	 */
	this.popupStay = 3000;//停留时间，毫秒，设置为popupInterval的整数倍
	/**
	 * 版本名
	 */
	this.currentVersion = _langPackage.setting.currentVersion;//"5107网站伴侣 在线版 Beta";
	/**
	 * Copyright设置
	 */
	this.copyRight = _langPackage.setting.copyRight;//"Copyright 2007 上海恒聚网络科技有限公司版权所有";
	/**
	 * 分页显示页数
	 */
	this.pageWc = 10;//显示页数
	/**
	 * 分页每页显示的记录数
	 */
	this.pageCount = 10;//每页显示的条数
	/**
	 * 请求状态访客的字体颜色
	 */
	this.requestBgColor = "#669900";
	/**
	 * 邀请状态访客的字体颜色
	 */
	this.inviteBgColor = "#669900";
	/**
	 * 交谈状态访客的字体颜色
	 */
	this.chatBgColor = "#ff6600";
	/**
	 * 离开状态访客的字体颜色
	 */
	this.leftBgColor = "#999999";
	/**
	 * 默认访客的字体颜色
	 */
	this.defaultColor = "#000000";
	/**
	 * 默认的弹出提示框设置，63表示111111
	 */
	this.defaultPopPrompt = 63;
	/**
	 * 默认声音提示设置，6表示110
	 */
	this.defaultSoundPrompt = 6;
	/**
	 * 修改公司信息的URL
	 */
	this.systemInfoEditUrl = "http://www.5107.cn/users/login/login.php";
	/**
	 * version Flags
	 */
	this.versionFlags = {
		phone : 1
	};
	/**
	 * debug flag
	 */
	this.debug = false;	
	/**
	 * default main frame
	 */
	this.defaultMain = 'monitor';
	/**
	 * 自动隐身时间设置，超过此时间没有进行动作将自动切换到 在线不交谈 状态
	 */
	this.autoHiddenTime = 300000;
}

/**
 * 设置页面风格
 */
function Setting_setStyle() {
	this.style = _style;
}

/**
 * 设置页面语言
 */
function Setting_setLanguage() {
	this.language = _language;
}

/**
 * 设置images/xmls/js的连接地址
 */
function Setting_set() {
	this.imagesPath = this.baseUrl + 'styles/' + this.style + '/' + this.language + '/images/';
	this.xmlsPath = this.baseUrl + 'xmls/' + this.language + '/';
	this.jsPath = this.baseUrl + 'js/';
	this.calPath = this.baseUrl + 'cal/';
}

/**
 * 初始化
 */
function Setting_init() {
	this.setStyle();
	this.setLanguage();
	this.set();
}

var _setting = new Setting();
_setting.init();
//-->
