<commit_before>function hide_lines_with_no_workload() {
  document.body.style.cursor = 'wait';
  $('loading').show();
  new Ajax.Request('/workloads/hide_lines_with_no_workload', {
    parameters: { on: $('hide_lines_with_no_workload').checked }
    });  
}

function hide_workload_menu() {
  $('wmenu').toggle();
  new Ajax.Request('/workloads/hide_wmenu', {
    parameters: { on: $('wmenu').style.display=='none' }
    });  
}

Ajax.Replacer = Class.create(Ajax.Updater, {
  initialize: function($super, container, url, options) {
    options = options || { };
    options.onComplete = (options.onComplete || Prototype.emptyFunction)
      .wrap(function(proceed, transport, json) {
        $(container).replace(transport.responseText);
        proceed(transport, json);
      })
    $super(container, url, options);
  }
})

function wl_add_line(person_id) {
  $('wl_line_add_form').appear({duration:0.2});
  }

function wl_save_value(line_id, wlweek) {
  new Ajax.Request('/workloads/edit_load?l='+line_id+'&w='+wlweek+'&v='+$(line_id+'_'+wlweek).value, {
    asynchronous:true,
    evalScripts:true
    });
  }

function wl_edit(line_id) {
  new Ajax.Request('/workloads/display_edit_line?l='+line_id, {
    asynchronous:true,
    evalScripts:true,
    onComplete: function(r) {new Draggable($('edit_line'));}
    });
}

function wl_change_colors(wlweek, background, color) {
  $('cpercent_'+wlweek).style.background  = background;
  $('cpercent_'+wlweek).style.color       = color;
  }

function change_workload(person_id) {
  document.body.style.cursor = 'wait';
  $('loading').show();
  new Ajax.Request('/workloads/change_workload', {
    parameters: { person_id: person_id }
    });
  }

function set_fixed_header() {
  $j('#workload_table').fixedHeaderTable({ height: '500', footer: false, fixedColumn: false });
  }

function display_milestones(evt,text) {
  var popup = $('milestones')
  var e = evt;
  popup.style.top = parseInt(Event.pointerY(e))+"px"
  popup.style.left = parseInt(Event.pointerX(e))+"px"
  popup.innerHTML = text;
  popup.show();
}
function hide_milestones(text) {
  $('milestones').hide();
  }
<commit_msg>Mantis 245<commit_after>function hide_lines_with_no_workload() {
  document.body.style.cursor = 'wait';
  $('loading').show();
  new Ajax.Request('/workloads/hide_lines_with_no_workload', {
    parameters: { on: $('hide_lines_with_no_workload').checked }
    });  
}

function hide_workload_menu() {
  $('wmenu').toggle();
  new Ajax.Request('/workloads/hide_wmenu', {
    parameters: { on: $('wmenu').style.display=='none' }
    });  
}

Ajax.Replacer = Class.create(Ajax.Updater, {
  initialize: function($super, container, url, options) {
    options = options || { };
    options.onComplete = (options.onComplete || Prototype.emptyFunction)
      .wrap(function(proceed, transport, json) {
        $(container).replace(transport.responseText);
        proceed(transport, json);
      })
    $super(container, url, options);
  }
})

function wl_add_line(person_id) {
  $('wl_line_add_form').appear({duration:0.2});
  }

function wl_save_value(line_id, wlweek) {
  new Ajax.Request('/workloads/edit_load?l='+line_id+'&w='+wlweek+'&v='+$(line_id+'_'+wlweek).value, {
    asynchronous:true,
    evalScripts:true
    });
  }

function wl_edit(line_id) {
  new Ajax.Request('/workloads/display_edit_line?l='+line_id, {
    asynchronous:true,
    evalScripts:true,
    onComplete: function(r) {new Draggable($('edit_line'));}
    });
}

function wl_change_colors(wlweek, background, color) {
  $('cpercent_'+wlweek).style.background  = background;
  $('cpercent_'+wlweek).style.color       = color;
  }

function change_workload(person_id) {
  document.body.style.cursor = 'wait';
  $('loading').show();
  new Ajax.Request('/workloads/change_workload', {
    parameters: { person_id: person_id }
    });
  }

function set_fixed_header() {
  $j('#workload_table').fixedHeaderTable({ height: '500', footer: false, fixedColumn: false });
  }

function display_milestones(evt,text) {
  var popup = $('milestones')
  var e = evt;
  popup.style.top  = e.clientY + "px";
  popup.style.left = e.clientX + "px";
  // popup.style.top = parseInt(Event.pointerY(e))+"px"
  // popup.style.left = parseInt(Event.pointerX(e))+"px"
  popup.innerHTML = text;
  popup.show();
}
function hide_milestones(text) {
  $('milestones').hide();
  }

{'fraction_non_alphanumeric': 0.17664601972929572, 'fraction_numerical': 0.0029823353980270705, 'mean_word_length': 4.443196004993758, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '4529284', 'n_tokens_mistral': 1576, 'n_tokens_neox': 1553, 'n_words': 215}