Merge branch 'release-1.34'
This commit is contained in:
commit
2a7ea52330
|
@ -80,7 +80,7 @@ fi;
|
|||
|
||||
if [ "$DISTROS" == "" ]; then
|
||||
if [ "$RELEASE" != "" ]; then
|
||||
DISTROS="xenial,bionic,eoan,focal"
|
||||
DISTROS="xenial,bionic,focal"
|
||||
else
|
||||
DISTROS=`lsb_release -a 2>/dev/null | grep Codename | awk '{print $2}'`;
|
||||
fi;
|
||||
|
|
|
@ -178,7 +178,8 @@ function applyPreset() {
|
|||
function toPixels(field, maxValue) {
|
||||
if ( field.value != '' ) {
|
||||
field.value = Math.round((field.value*maxValue)/100);
|
||||
if ( field.value > maxValue ) field.value = maxValue;
|
||||
if ( field.value > maxValue )
|
||||
field.value = maxValue;
|
||||
}
|
||||
field.setAttribute('step', 1);
|
||||
field.setAttribute('max', maxValue);
|
||||
|
@ -249,14 +250,12 @@ function limitArea(field) {
|
|||
limitRange(field, minValue, maxValue);
|
||||
}
|
||||
|
||||
function highlightOn(point) {
|
||||
var index = point.getAttribute('data-index');
|
||||
function highlightOn(index) {
|
||||
$('row'+index).addClass('highlight');
|
||||
$('point'+index).addClass('highlight');
|
||||
}
|
||||
|
||||
function highlightOff(point) {
|
||||
var index = point.getAttribute('data-index');
|
||||
function highlightOff(index) {
|
||||
$('row'+index).removeClass('highlight');
|
||||
$('point'+index).removeClass('highlight');
|
||||
}
|
||||
|
@ -328,17 +327,15 @@ function addPoint(index) {
|
|||
if ( index >= (zone['Points'].length-1) ) {
|
||||
nextIndex = 0;
|
||||
}
|
||||
|
||||
var newX = parseInt(Math.round((zone['Points'][index]['x']+zone['Points'][nextIndex]['x'])/2));
|
||||
var newY = parseInt(Math.round((zone['Points'][index]['y']+zone['Points'][nextIndex]['y'])/2));
|
||||
if ( nextIndex == 0 ) {
|
||||
zone['Points'][zone['Points'].length] = {'x': newX, 'y': newY};
|
||||
} else {
|
||||
zone['Points'].splice( nextIndex, 0, {'x': newX, 'y': newY} );
|
||||
zone['Points'].splice(nextIndex, 0, {'x': newX, 'y': newY});
|
||||
}
|
||||
drawZonePoints();
|
||||
// drawZonePoints calls updateZoneImage
|
||||
//updateZoneImage();
|
||||
//setActivePoint( nextIndex );
|
||||
}
|
||||
|
||||
function delPoint(index) {
|
||||
|
@ -421,10 +418,9 @@ function drawZonePoints() {
|
|||
'top': zone['Points'][i].y
|
||||
}
|
||||
});
|
||||
//div.addEvent('mouseover', highlightOn.pass(i));
|
||||
div.onmouseover = window['highlightOn'].bind(div, div);
|
||||
div.onmouseout = window['highlightOff'].bind(div, div);
|
||||
div.addEvent('mouseover', highlightOn.pass(i));
|
||||
div.addEvent('mouseout', highlightOff.pass(i));
|
||||
|
||||
div.inject($('imageFrame'));
|
||||
div.makeDraggable( {
|
||||
'container': $('imageFrame'),
|
||||
|
@ -493,7 +489,7 @@ function drawZonePoints() {
|
|||
cell.inject(row);
|
||||
|
||||
row.inject(tables[i%tables.length].getElement('tbody'));
|
||||
}
|
||||
} // end foreach point
|
||||
// Sets up the SVG polygon
|
||||
updateZoneImage();
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue