/*
 * Ext JS Library 2.0
 * Copyright(c) 2006-2007, Ext JS, LLC.
 * licensing@extjs.com
 * 
 * http://extjs.com/license
 */

Ext.onReady(function(){
    var win;
    var button = Ext.get('privacy-popup');

    button.on('click', function(){
        // create the window on the first click and reuse on subsequent clicks
        if(!win){
            win = new Ext.Window({
                el:'privacy-win',
                layout:'fit',
                width:610,
                height:650,
                closeAction:'hide',
                plain: true,
                
                items: new Ext.TabPanel({
                    el: 'privacy-tabs',
                    autoTabs:true,
                    bodyStyle: 'padding: 10px 10px 10px 10px',
                    activeTab:0,
                    deferredRender:false,
                    border:false
                }),

                buttons: [{
                    text: 'French Translation',
                    handler: translatePrivacy
					},{
                    text: 'Close',
                    handler: function(){
                        win.hide();
                    }
                }]
            });
        }
        win.show(this);
    });
function translatePrivacy(){
if(navigator.appName == "Microsoft Internet Explorer"){
window.open("http://uk.babelfish.yahoo.com/translate_url?doit=done&fr=bf-badge&trurl=http://www.mufts.com/privacyPolicy.html&lp=en_fr", null, "height=600,width=800,status=no,toolbar=no,menubar=no,location=no,titlebar=no,resizable=yes");
} else {
window.open("http://uk.babelfish.yahoo.com/translate_url?doit=done&fr=bf-badge&trurl=privacyPolicy.html&lp=en_fr", null, "height=600,width=800,status=no,toolbar=no,menubar=no,location=no,titlebar=no,resizable=yes");

}
}
});