1/**
2 * Remove go button from translation dropdown
3 */
4addInitEvent(function(){
5    var frm = $('translation__dropdown');
6    if(!frm) return;
7    frm.elements['go'].style.display = 'none';
8    addEvent(frm.elements['id'],'change',function(e){
9        var id = e.target.options[e.target.selectedIndex].value;
10        // this should hopefully detect rewriting good enough:
11        if(frm.action.substr(frm.action.length-1) == '/'){
12            var link = frm.action + id;
13        }else{
14            var link = frm.action + '?id=' + id;
15        }
16
17        window.location.href= link;
18    });
19});
20