﻿Globals.CustomScriptWindow = function() {
    
    var txtArea = new Ext.form.TextArea({
        height: 200,
        width: 280,
        emptyText : 'http://some.domain.com/yourscript.js, http://...',
        fieldLabel : 'Enter script urls (including http://) separated by ,'
    });
    
    var win = new Ext.Window({
        title : 'Analyze your own scripts!',
        height : 310,
        width : 350,
        modal : true,
        layout : 'form',
        labelWidth : 220,
        labelAlign : 'top',
        bodyStyle : 'padding:10px',
        buttons : [{
            text : 'Analyze',
            handler : function() {
                win.fireEvent('dataentered', win, txtArea.getValue());
                                win.close();
            },
            scope : this
        }],
        items : [
           txtArea
        ]
    });
    
    win.addEvents('dataentered');
    return win;
};