diff options
author | Pooja Soundalgekar | 2016-07-13 00:01:01 +0530 |
---|---|---|
committer | Pooja Soundalgekar | 2016-07-13 00:01:01 +0530 |
commit | ce05ba7adb6aa74508924360660ae442d3e2e5bd (patch) | |
tree | dea44d958f19b683836a79a1d37033c14b18d9d9 /index.html | |
parent | 69ab3cbceb9c9efa281e3ec6e17cc884ea6c10ad (diff) | |
download | xcos-on-web-ce05ba7adb6aa74508924360660ae442d3e2e5bd.tar.gz xcos-on-web-ce05ba7adb6aa74508924360660ae442d3e2e5bd.tar.bz2 xcos-on-web-ce05ba7adb6aa74508924360660ae442d3e2e5bd.zip |
made final changes
Diffstat (limited to 'index.html')
-rwxr-xr-x | index.html | 19 |
1 files changed, 12 insertions, 7 deletions
@@ -734,13 +734,15 @@ } var flip = false, mirror = false; - if(cell.style.indexOf('stencilFlipV') == -1){ + var style = cell.style; + var styleObject = styleToObject(style); + if(styleObject['stencilFlipV'] == null){ flip = false; } else { - var x = cell.style.indexOf('stencilFlipV'); - if(cell.style.charAt(x+13) == 0){ + + if(styleObject['stencilFlipV'] == 0){ flip = false; } else{ @@ -748,13 +750,13 @@ } } - if(cell.style.indexOf('stencilFlipH') == -1){ + if(styleObject['stencilFlipH'] == null){ mirror = false; } else { - var x = cell.style.indexOf('stencilFlipH'); - if(cell.style.charAt(x+13) == 0){ + + if(styleObject['stencilFlipH'] == 0 ){ mirror = false; } else{ @@ -762,6 +764,7 @@ } } + style = objectToStyle(styleObject); var geometry = cell.getGeometry(); text = 'Block Name : ' + cell.value.getAttribute('blockElementName') + "\n" + 'Simulation : ' + cell.value.getAttribute('simulationFunctionName') + "\n" + @@ -1688,7 +1691,9 @@ if (style.indexOf(';') == -1) { style = style + ';'; } - + else if ( style[style.length-1] != ';'){ + style = style + ';'; + } var defaultStyle = style.substring(0, style.indexOf(';')); var styleObject = { "default": defaultStyle |