diff --git a/browser/css/dark.css b/browser/css/dark.css index bf642eaf3e7420e7f22e93470cdc369d9dce5698..c0990cc3bc216b00edbfc51fd9d2aec5ca13b8a0 100644 --- a/browser/css/dark.css +++ b/browser/css/dark.css @@ -705,7 +705,8 @@ span .substitution { .popup_container a:hover { color: #fdf6e3; } -#data-container { +.data-container, +.info-container { z-index: 3; border: solid; position: fixed; @@ -722,8 +723,9 @@ span .substitution { height: -webkit-calc(100% - 200px); height: calc(100% - 200px); } -#data-msg { - overflow: auto; +.data-msg, +.info-msg { + overflow-x: hidden; height: 100%; width: 100%; } diff --git a/browser/css/light.css b/browser/css/light.css index 99bfab4171c403b989b48e9569c03b9be30f5d24..1d192a7b18f5710dfdef5b6a8916bb5db569d8b3 100644 --- a/browser/css/light.css +++ b/browser/css/light.css @@ -705,7 +705,8 @@ span .substitution { .popup_container a:hover { color: #002b36; } -#data-container { +.data-container, +.info-container { z-index: 3; border: solid; position: fixed; @@ -722,8 +723,9 @@ span .substitution { height: -webkit-calc(100% - 200px); height: calc(100% - 200px); } -#data-msg { - overflow: auto; +.data-msg, +.info-msg { + overflow-x: hidden; height: 100%; width: 100%; } diff --git a/browser/css/vidjil.less b/browser/css/vidjil.less index 7d7efdc3e672d8430e25d32b3323c524feb6d84b..82d6a14247ceea4cd1f7a4a5a5b97f9d5c1fbe08 100644 --- a/browser/css/vidjil.less +++ b/browser/css/vidjil.less @@ -852,7 +852,7 @@ span .substitution{ color : @select; } -#data-container{ +.data-container, .info-container{ z-index:3; border:solid; position: fixed; @@ -870,8 +870,8 @@ span .substitution{ height: calc(~"100%" - 200px); } -#data-msg{ - overflow: auto; +.data-msg, .info-msg{ + overflow-x: hidden; height : 100%; width : 100%; } diff --git a/browser/index.html b/browser/index.html index 5060ffa506960f8a280e8071260a5338431ea247..ce0b3774aaf3b27a553229491f1798c542c26cec 100644 --- a/browser/index.html +++ b/browser/index.html @@ -249,20 +249,20 @@
- +
- +
- +
- +
...
@@ -271,17 +271,10 @@
-
- -
- X -
-
-
diff --git a/browser/js/com.js b/browser/js/com.js index 0a552fdab82e776341f8552d433fae327e03b931..c821cdeab1ce1abac6bc6877bbe8c90da6e7a043 100644 --- a/browser/js/com.js +++ b/browser/js/com.js @@ -143,6 +143,23 @@ Com.prototype = { document.body.appendChild(this.flash_container); document.body.appendChild(this.log_container); document.body.appendChild(this.popup_container); + + + + this.div_dataBox = document.createElement("div"); + this.div_dataBox.className = "data-container"; + + var closedataBox = document.createElement("span"); + closedataBox.className = "closeButton" ; + closedataBox.appendChild(document.createTextNode("X")); + closedataBox.onclick = function() {self.closeDataBox()}; + this.div_dataBox.appendChild(closedataBox); + + var div_data = document.createElement("div"); + div_data.className = "data-msg"; + this.div_dataBox.appendChild(div_data); + + document.body.appendChild(this.div_dataBox); }, @@ -221,17 +238,13 @@ Com.prototype = { }, dataBox: function(msg) { - document.getElementById(this.data_id) - .style.display = "block"; - document.getElementById(this.data_id).lastElementChild - .innerHTML = msg; + this.div_dataBox.style.display = "block"; + this.div_dataBox.lastElementChild.innerHTML = msg; }, closeDataBox: function() { - document.getElementById(this.data_id) - .style.display = "none"; - document.getElementById(this.data_id).lastElementChild - .innerHTML = ""; + this.div_dataBox.style.display = "none"; + this.div_dataBox.lastElementChild.innerHTML = ""; } } diff --git a/browser/js/list.js b/browser/js/list.js index 5908dd5c987f9f0d023ce28ea8314d273e867ef0..eadd95061a33d03794ecb9747ed2b5796008dce1 100644 --- a/browser/js/list.js +++ b/browser/js/list.js @@ -114,9 +114,26 @@ List.prototype = { $(self.dataMenu).hide('fast') } + //build infoBox + + this.infoBox = document.createElement("div"); + this.infoBox.className = "info-container"; + + var closeinfoBox = document.createElement("span"); + closeinfoBox.className = "closeButton" ; + closeinfoBox.appendChild(document.createTextNode("X")); + closeinfoBox.onclick = function() {self.closeInfoBox()}; + this.infoBox.appendChild(closeinfoBox); + + var div_info = document.createElement("div"); + div_info.className = "info-msg"; + this.infoBox.appendChild(div_info); + //add to body document.body.appendChild(this.tagSelector); document.body.appendChild(this.dataMenu); + document.body.appendChild(this.infoBox); + }, /* initialise la liste et crée un div pour chaque clones @@ -404,7 +421,7 @@ List.prototype = { var span_info = document.createElement('span') span_info.className = "infoBox"; span_info.onclick = function () { - console.dataBox(self.m.clone(cloneID).getHtmlInfo()); + self.displayInfoBox(self.m.clone(cloneID).getHtmlInfo()); } span_info.appendChild(document.createTextNode("I")); @@ -486,7 +503,7 @@ List.prototype = { var span_info = document.createElement('span') span_info.className = "infoBox"; span_info.onclick = function () { - console.dataBox(self.m.clone(this.parentNode.id2).getHtmlInfo()); + self.displayInfoBox(self.m.clone(this.parentNode.id2).getHtmlInfo()); } span_info.appendChild(document.createTextNode("I")); @@ -894,6 +911,16 @@ List.prototype = { $(this.dataMenu).show("fast"); this.dataMenuInfo.innerHTML = data; }, + + displayInfoBox: function(msg) { + this.infoBox.style.display = "block"; + this.infoBox.lastElementChild.innerHTML = msg; + }, + + closeInfoBox: function() { + this.infoBox.style.display = "none"; + this.infoBox.lastElementChild.innerHTML = ""; + } } //fin prototype