Commit cfbb1cd8 authored by Mikaël Salson's avatar Mikaël Salson Committed by Vidjil Team

js/crossDomain.js: Make sure checkbox is unchecked

This could differ between browsers.
The click() method was not interpreted in the same way in Chrome and Firefox.
It was working with Chrome, not with Firefox.
parent e9a82bd8
......@@ -253,6 +253,7 @@ function imgtPostForSegmenter(species, data, system, segmenter, override_imgt_op
var input = document.createElement('input');
input.type = 'checkbox';
input.id = 'imgt_cdr3_input_check';
input.checked = false;
$(input).on("click", function() {
if(this.checked) {
segmenter.highlight[1].field = "CDR3-IMGT";
......@@ -264,7 +265,6 @@ function imgtPostForSegmenter(species, data, system, segmenter, override_imgt_op
segmenter.update();
});
input.click();
var label = document.createElement('label');
label.setAttribute("for", 'imgt_cdr3_input_check');
label.innerHTML = 'CDR3-IMGT';
......@@ -278,6 +278,7 @@ function imgtPostForSegmenter(species, data, system, segmenter, override_imgt_op
input = document.createElement('input');
input.type = 'checkbox';
input.id = 'imgt_vdj_input_check';
input.checked = false;
$(input).on("click", function() {
if(this.checked) {
segmenter.highlight[2].field = "V-REGION";
......@@ -295,7 +296,6 @@ function imgtPostForSegmenter(species, data, system, segmenter, override_imgt_op
segmenter.update();
});
input.click();
label = document.createElement('label');
label.setAttribute("for", 'imgt_vdj_input_check');
label.innerHTML = "V/D/J-IMGT";
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment