OV.SettingsSidebarPanel = class extends OV.SidebarPanel
{
constructor (parentDiv)
{
super (parentDiv);
this.backgroundColorInput = null;
this.defaultColorInput = null;
}
GetTitle ()
{
return 'Settings';
}
InitSettings (settings, defaultSettings, callbacks)
{
this.backgroundColorInput = this.AddColorParameters ('Background Color', 'Changing the background color affects only the visualization.', settings.backgroundColor, callbacks.onBackgroundColorChange);
this.defaultColorInput = this.AddColorParameters ('Default Color', 'Default color is used when no material was defined in the file.', settings.defaultColor, callbacks.onDefaultColorChange);
this.AddResetToDefaultsButton (defaultSettings, callbacks);
}
AddColorParameters (title, description, defaultValue, onChange)
{
$('
').addClass ('ov_sidebar_subtitle').html (title).appendTo (this.contentDiv);
let contentDiv = $('
').addClass ('ov_sidebar_settings_content').appendTo (this.contentDiv);
let colorColumn = $('