function ckSWFObj() { //sMovieURL,w,h,bgcolor
	var args = ckSWFObj.arguments;
	
	this.aFlashvars = new Array();
	this.aParams = new Array();
	this.aAttributes = new Array();
	this.aStyle = new Array();
	
	this.movieURL = (args.length >= 1 ? args[0] : ""); 
	if (args.length >= 3) this.setMovieSize(args[1],args[2]);
	if (args.length >= 4) this.setBackgroundColor(args[3]);

	this.movieID = "";
	this.setRequiredVersion("8.0.0");
	
	return this;
}

/*--------------------------------------------------------------------------------
Add
--------------------------------------------------------------------------------*/
ckSWFObj.prototype.addVariablesFromArray = function(aVars) {
	for (var name in aVars) this.addVariable(name,aVars[name]);
}

ckSWFObj.prototype.addVariable = function(name,value) {
	this.aFlashvars[name] = value;
}
ckSWFObj.prototype.addParam = function(name,value) {
	this.aParams[name] = value;
}
ckSWFObj.prototype.addContainerAttribute = function(name,value) {
	this.aAttributes[name] = value;
}
ckSWFObj.prototype.addContainerStyle = function(name,value) {
	this.aStyle[name] = value;
}
/*--------------------------------------------------------------------------------
Set
--------------------------------------------------------------------------------*/
ckSWFObj.prototype.setWMode = function(sMode) {
	this.addParam("wmode",sMode);
}
ckSWFObj.prototype.setRequiredVersion = function(sVersion) {
	this.requiredVersion = sVersion;
}
ckSWFObj.prototype.setMovieID = function(sMovieID) {
	this.movieID = sMovieID;
}
ckSWFObj.prototype.setBackgroundColor = function(bgcolor) {
	this.addParam("bgcolor",bgcolor);
}
ckSWFObj.prototype.setMovieSize = function(w,h) {
	this.width = w;
	this.height = h;
	
	this.addContainerStyle("width",w + "px");
	this.addContainerStyle("height",h + "px");
	
}
/*--------------------------------------------------------------------------------
video playback
--------------------------------------------------------------------------------*/
ckSWFObj.prototype.setupVideoPlayback = function(videoURL,videoWidth,videoHeight,bgcolor) {
	this.movieURL = "/_ckcommon/flash/videoPlayback.swf";
	this.addVariable("videoURL",videoURL);
	this.addVariable("videoWidth",videoWidth);
	this.addVariable("videoHeight",videoHeight);
	
	//these params assume no video expansion feature
	this.setMovieSize(videoWidth+16,videoHeight+80);
	this.setBackgroundColor(bgcolor);
}
	
/*--------------------------------------------------------------------------------
Embed
--------------------------------------------------------------------------------*/

ckSWFObj.prototype.embed = function(containerID) {
	var sStyle = "";
	for (var key in this.aStyle) {
		sStyle += (sStyle != "" ? ";" : "") + key + ":" + this.aStyle[key];
	}
	if (sStyle != "") this.addContainerAttribute("style",sStyle);
	
	if (this.movieID == "") this.setMovieID(containerID + ".ckFlash");
	
	swfobject.embedSWF(this.movieURL,containerID,this.width,this.height,this.requiredVersion,"/_ckcommon/libraries/flash/expressInstall.swf",this.aFlashvars, this.aParams, this.aAttributes);
}
