Ext.define('Ext.ux.grid.column.ActionColumn', {
	extend: 'Ext.grid.column.Action',
	alias: ['widget.ip2actioncolumn', 'widget.ip2ActionColumn'],

	constructor: function(config) {
		var me = this,
		cfg = Ext.apply({}, config),
            
		items = cfg.items || me.items || [me],
		hasGetClass,
		i,
		len;

		me.origRenderer = cfg.renderer || me.renderer;
		me.origScope = cfg.scope || me.scope;
        
		me.renderer = me.scope = cfg.renderer = cfg.scope = null;
        
		cfg.items = null;
		cfg.width = 22;
		cfg.align = 'center';
		cfg.iconCls = 'ip2-gridaction-icon ip2-ux-icon-' + cfg.icon.toLowerCase();
		cfg.icon = null;

		me.callParent([cfg]);
            
		me.items = items;

		for (i = 0, len = items.length; i < len; ++i) {
			if (items[i].getClass) {
				hasGetClass = true;
				break;
			}
		}
        
		if (me.origRenderer || hasGetClass) {
			me.hasCustomRenderer = true;
		}
	}     
});
