/**
 * Create a BoxArea ajax handler.
 */
function BoxArea(area, url, module, action)
{
	this.el = $('#box_area_'+area);
	this.area = area;
	this.url = url;
	this.setup();
	this.module = module;
	this.action = action;
}

// Pull in the base class definition
BoxArea.prototype = new AjaxElement(null, null);

BoxArea.prototype.data = function()
{
	return this.el.sortable('serialize') + '&' + 'boxarea=' + this.area + '&' + 'module=' + this.module + '&' + 'action=' + this.action;
}

BoxArea.prototype.setup = function()
{
	var me = this; // Needed to create a closure
	
	this.el.sortable({
		stop : function(i) { me.callback(); }
	});
}
