aspnet_client/FreeTextBox/FTB-ToolbarItems.js

(开头部分) 3KB

这里只显示每个文件的开头 60 行。登录后可以解锁完整代码。

/* FTB_Button
---------------------------------------------- */
function FTB_Button(id, commandIdentifier, customAction, customStateQuery, htmlModeEnabled, customEnabled) {
	this.state = FTB_BUTTON_OFF;
	this.id = id;
	this.ftb = null;
	this.commandIdentifier = commandIdentifier;
	this.customAction = customAction;
	this.customStateQuery = customStateQuery;	
	
	this.disabled = false;
	this.htmlModeEnabled = htmlModeEnabled	;
	this.customEnabled = customEnabled;
	
	this.td = document.getElementById(id);
	this.td.button = this;
	
	if (FTB_Browser.isIE) {		
		this.buttonImage = this.td.childNodes[0];
	} else {
		this.buttonImage = this.td.childNodes[1];
	}
};
FTB_Button.prototype.Initialize = function() {
	var id=this.td.button.id;
	FTB_AddEvent(this.td,"click",function() { if(FTB_Browser.isIE) document.getElementById(id).button.Click(); else this.button.Click(); } );
	FTB_AddEvent(this.td,"mouseover",function() { if(FTB_Browser.isIE) document.getElementById(id).button.MouseOver(); else this.button.MouseOver(); } );
	FTB_AddEvent(this.td,"mouseout",function() { if(FTB_Browser.isIE) document.getElementById(id).button.MouseOut(); else this.button.MouseOut(); } );
};
FTB_Button.prototype.Click = function() {
	if (!this.disabled) {
		
		if (this.customAction) 			
			this.customAction();	
		else if (this.commandIdentifier != null && this.commandIdentifier != '') 
			this.ftb.ExecuteCommand(this.commandIdentifier);

		this.ftb.Event();
		
	}
};
FTB_Button.prototype.MouseOver = function() {
	if (!this.disabled) this.SetButtonBackground("Over");
};
FTB_Button.prototype.MouseOut = function() {
	if (!this.disabled) this.SetButtonBackground("Out");
};
FTB_Button.prototype.SetButtonBackground = function(mouseState) {
		this.SetButtonStyle(mouseState);
}
FTB_Button.prototype.SetButtonStyle = function(mouseState) {
	this.td.className = this.ftb.id + "_Button_" + ((this.state == FTB_BUTTON_ON) ? "On" : "Off") + "_" + mouseState;
}

/* FTB_DropDownList
---------------------------------------------- */

function FTB_DropDownList(id, commandIdentifier, customAction, customStateQuery, customEnabled) {
	this.id = id;
	this.ftb = null;
后面还有 34 行代码,购买后查看完整代码

24 小时内免费解锁 3 个项目,之后 1 积分/个。 规则说明

AI 解读 AI

登录后可用,每次 10 积分,解读结果公开显示在下面。

还没有人解读过这个文件。