rem: if (paramType == 'text') { 
add: if (paramType == 'text' || paramType == 'choice') { 
context: function bsw_BlockPreference(key, blockId, values) {    this.id = bsw_PREF_ID++;    if (!bsw_USER_BLOCKS[key]) {	bsw_USER_BLOCKS[key] = new Array();    }    if (!bsw_USER_BLOCK_POSITIONS[key]) {	bsw_USER_BLOCK_POSITIONS[key] = new Array();    }    bsw_USER_BLOCKS[key][this.id] = this;    bsw_USER_BLOCK_POSITIONS[key].push(this.id);    this.blockKey = key;    this.blockId = blockId;    this.parameters = new Array();    this.setParameterValue = function(paramName, value) {	this.parameters[paramName] = value;    };    this.toString = function() {	var result = '["' + this.blockId + '",{';	var count = 0;	for (var paramName in this.parameters) {	    var paramValue = this.parameters[paramName];	    var defaultValue =		bsw_WIDGET_BLOCKS[key][blockId]['parameters'][paramName]['defaultValue'];	    var paramType = bsw_WIDGET_BLOCKS[key][blockId]['parameters'][paramName]['type'];	    if (paramValue != defaultValue) {		if (count++) {		    result += ',';		}		result += '"' + paramName + '":';		if (paramType == 'text') {		    result += '"' + paramValue.replace(/\"/g,'\\"') + '"';		} else {		    result += paramValue;		}	    }	}	result += '}]';	return result;    };    /* Set the defaults */    if (bsw_WIDGET_BLOCKS[key][blockId]) {	for (var value in bsw_WIDGET_BLOCKS[key][blockId]['parameters']) {	    this.setParameterValue(		value, bsw_WIDGET_BLOCKS[key][blockId]['parameters'][value]['defaultValue']);	}    } else {	/*	 * Unknown block.   Uncomment this for debugging purposes.	 * alert('undefined block type: ' + blockId);	 */    }    /* Override whatever we're specifically changing */    for (var value in values) {	this.setParameterValue(value, values[value]);    }}
meta: 3727	/local1/tlutelli/issta_data/temp/all_js/javascript/2006_temp/2006/3727/e0738fa4023f0854678dffb33b815e7158635c89/BlockSelectWidget.js/clean/gallery2/lib/javascript/BlockSelectWidget.js