Commit 71291e1a authored by Mathieu Giraud's avatar Mathieu Giraud Committed by Marc Duez
Browse files

builder.js: multi-germline menu with SystemBoxMenu

parent 686bf290
......@@ -447,7 +447,7 @@ line {
}
.systemBox {
.systemBox, .systemBoxMenu {
display: inline-block;
width: @width_systemBox;
height: 16px;
......@@ -455,13 +455,22 @@ line {
border-radius: 3px;
border-style: solid;
border-width: 1px;
float: left;
margin : 2px;
margin-top: 0px;
color: @select;
font-family: monospace;
}
.systemBox {
float: left;
}
.systemBoxNameMenu {
display: inline-block;
min-width: 90px;
}
.clusterBox{
width: @width_clusterBox;
float: left;
......
......@@ -628,8 +628,24 @@ Builder.prototype = {
checkbox.onchange = function () {
m.update_selected_system()
}
var span_system = document.createElement('span')
span_system.className = "systemBoxMenu";
/* TODO: factorize with list.js */
if ((typeof key != 'undefined') && (typeof germline.icon[key] != 'undefined')){
span_system.appendChild(document.createTextNode(germline.icon[key].letter));
span_system.style.background = germline.icon[key].color
span_system.title = key
}else{
span_system.appendChild(document.createTextNode("?"));
if (typeof key != 'undefined')
span_system.title = key ;
}
var span = document.createElement('span');
span.className = "systemBoxNameMenu";
span.appendChild(span_system)
span.appendChild(checkbox)
span.appendChild(document.createTextNode(key))
......
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