tweaking...

Signed-off-by: Alex A. Naanou <alex.nanou@gmail.com>
This commit is contained in:
Alex A. Naanou 2020-05-17 18:27:03 +03:00
parent f0a6b5cb8f
commit 1427a327eb

View File

@ -487,8 +487,9 @@ object.Constructor('igImageGraph', HTMLElement, {
var button = document.createElement('button') var button = document.createElement('button')
button.setAttribute('id', 'orientation-button') button.setAttribute('id', 'orientation-button')
button.classList.add('update') button.classList.add('update')
//button.innerHTML = '&#9637;' button.innerHTML = '&#129105;'
button.innerHTML = '&#8597;' button.style.marginTop = '-2px'
//button.innerHTML = '&#8597;'
button.disabled = that.graph != 'waveform' button.disabled = that.graph != 'waveform'
var o = that.orientation || 0 var o = that.orientation || 0
button.onclick = function(){ button.onclick = function(){
@ -500,11 +501,13 @@ object.Constructor('igImageGraph', HTMLElement, {
: that.orientation == 270 ? : that.orientation == 270 ?
180 180
: 0 : 0
this.style.transform = 'rotate('+(o == n ? 0 : -90)+'deg)' // update button orientation...
this.style.transform = 'rotate('+(o == n ? 0 : 90)+'deg)'
this.style.marginTop = o == n ? '-2px' : '-1px'
} }
return button }(), return button }(),
// modes... // modes...
(this.nocontrols ? ...(this.nocontrols ?
[] []
: this.modes) : this.modes)
// mode buttons... // mode buttons...
@ -535,7 +538,6 @@ object.Constructor('igImageGraph', HTMLElement, {
button.onclick = function(){ that.update() } button.onclick = function(){ that.update() }
return button }(), return button }(),
] ]
.flat()
.reverse() .reverse()
.forEach(function(button){ .forEach(function(button){
controls.appendChild(button) }) controls.appendChild(button) })