Modifications for test.

This commit is contained in:
kovacsv 2021-06-20 15:37:53 +02:00
parent 12706c7f6a
commit e8ba400a3b
3 changed files with 7 additions and 3 deletions

View File

@ -52,7 +52,10 @@ OV.Sidebar = class
} else if (property.type === OV.PropertyType.Integer) { } else if (property.type === OV.PropertyType.Integer) {
valueText = property.value.toLocaleString (); valueText = property.value.toLocaleString ();
} else if (property.type === OV.PropertyType.Number) { } else if (property.type === OV.PropertyType.Number) {
valueText = property.value.toFixed (2); valueText = property.value.toLocaleString (undefined, {
minimumFractionDigits: 2,
maximumFractionDigits: 2
});
} else if (property.type === OV.PropertyType.Percent) { } else if (property.type === OV.PropertyType.Percent) {
valueText = parseInt (property.value * 100, 10).toString () + '%'; valueText = parseInt (property.value * 100, 10).toString () + '%';
} else if (property.type === OV.PropertyType.Color) { } else if (property.type === OV.PropertyType.Color) {

View File

@ -18,6 +18,7 @@ OV.ToolbarButton = class
if (this.onClick !== null) { if (this.onClick !== null) {
this.buttonDiv.click (this.onClick); this.buttonDiv.click (this.onClick);
} }
this.buttonDiv.attr ('alt', this.imageTitle);
OV.InstallTooltip (this.buttonDiv, this.imageTitle); OV.InstallTooltip (this.buttonDiv, this.imageTitle);
this.Update (); this.Update ();
} }

View File

@ -283,7 +283,7 @@ OV.Website = class
}); });
}); });
AddSeparator (this.toolbar); AddSeparator (this.toolbar);
AddButton (this.toolbar, 'fit', 'Fit model to Window', false, function () { AddButton (this.toolbar, 'fit', 'Fit model to window', false, function () {
obj.FitModelToWindow (false); obj.FitModelToWindow (false);
}); });
AddButton (this.toolbar, 'up_y', 'Set Y axis as up vector', false, function () { AddButton (this.toolbar, 'up_y', 'Set Y axis as up vector', false, function () {
@ -330,7 +330,7 @@ OV.Website = class
}); });
}); });
} }
AddRightButton (this.toolbar, 'details', 'Details Panel', true, function () { AddRightButton (this.toolbar, 'details', 'Details panel', true, function () {
obj.ShowSidebar (!obj.sidebar.IsVisible ()); obj.ShowSidebar (!obj.sidebar.IsVisible ());
}); });