function translateChart(chartOrEvent){
        var chart = chartOrEvent.target ? chartOrEvent.target : chartOrEvent;

        //Translate menu-items in the export-menu but only when the fullscreen is not open
        if (chart.fullscreen && !chart.fullscreen.isOpen){
            var menuItems = checkPath(chart, 'options.exporting.buttons.contextButton.menuItems');
            $.each(menuItems, function(index, id){
                var elem = chart.exportDivElements ? chart.exportDivElements[index] : null;
                translateElement(elem, chart.options.lang, id);
            });
        }

        $.each(chart.series, function(index, serie){
            //Translate valuePrefix amd valueSuffix of tooltips - both in original optiona and in shortcut version
            if ( checkPath(serie, 'tooltipOptions.valuePrefix') )
                translateElement(null, serie.tooltipOptions, 'valuePrefix');
            if ( checkPath(serie, 'options.tooltip.valuePrefix') )
                translateElement(null, serie.options.tooltip, 'valuePrefix');

            if ( checkPath(serie, 'tooltipOptions.valueSuffix') )
                translateElement(null, serie.tooltipOptions, 'valueSuffix');
            if ( checkPath(serie, 'options.tooltip.valueSuffix') )
                translateElement(null, serie.options.tooltip, 'valueSuffix');
        });

        //Translate range-selector buttons and drop-down
        if (chart.rangeSelector){
            $.each(chart.rangeSelector.buttonOptions, function(index, buttonOpt){
                //Translate button
                translateElement(null, buttonOpt, 'text');
                translateElement(null, buttonOpt, 'title');

                //Translate options in select
                chart.rangeSelector.dropdown[index+1].innerHTML = buttonOpt.title || buttonOpt.text;
            });
            //Align elemnets (buttons and select) to update select
            chart.rangeSelector.alignElements();
        }
    }
/****************************************************
    translateChart(chartOrEvent)
    Translate the different parts of a chart that is not
    re-created on reset
    *****************************************************/
translateChart(chartOrEvent)
Translate the different parts of a chart that is not
re-created on reset
translateChart ( chartOrEvent ) Translate the different parts of a chart that is not re - created on reset
function translateChart(chartOrEvent){
        var chart = chartOrEvent.target ? chartOrEvent.target : chartOrEvent;
        if (chart.fullscreen && !chart.fullscreen.isOpen){
            var menuItems = checkPath(chart, 'options.exporting.buttons.contextButton.menuItems');
            $.each(menuItems, function(index, id){
                var elem = chart.exportDivElements ? chart.exportDivElements[index] : null;
                translateElement(elem, chart.options.lang, id);
            });
        }
        $.each(chart.series, function(index, serie){
            if ( checkPath(serie, 'tooltipOptions.valuePrefix') )
                translateElement(null, serie.tooltipOptions, 'valuePrefix');
            if ( checkPath(serie, 'options.tooltip.valuePrefix') )
                translateElement(null, serie.options.tooltip, 'valuePrefix');
            if ( checkPath(serie, 'tooltipOptions.valueSuffix') )
                translateElement(null, serie.tooltipOptions, 'valueSuffix');
            if ( checkPath(serie, 'options.tooltip.valueSuffix') )
                translateElement(null, serie.options.tooltip, 'valueSuffix');
        });
        if (chart.rangeSelector){
            $.each(chart.rangeSelector.buttonOptions, function(index, buttonOpt){
                translateElement(null, buttonOpt, 'text');
                translateElement(null, buttonOpt, 'title');
                chart.rangeSelector.dropdown[index+1].innerHTML = buttonOpt.title || buttonOpt.text;
            });
            chart.rangeSelector.alignElements();
        }
    }
function translateChart ( chartOrEvent ) { var chart = chartOrEvent . target ? chartOrEvent . target : chartOrEvent ; if ( chart . fullscreen && ! chart . fullscreen . isOpen ) { var menuItems = checkPath ( chart , 'options.exporting.buttons.contextButton.menuItems' ) ; $ . each ( menuItems , function ( index , id ) { var elem = chart . exportDivElements ? chart . exportDivElements [ index ] : null ; translateElement ( elem , chart . options . lang , id ) ; } ) ; } $ . each ( chart . series , function ( index , serie ) { if ( checkPath ( serie , 'tooltipOptions.valuePrefix' ) ) translateElement ( null , serie . tooltipOptions , 'valuePrefix' ) ; if ( checkPath ( serie , 'options.tooltip.valuePrefix' ) ) translateElement ( null , serie . options . tooltip , 'valuePrefix' ) ; if ( checkPath ( serie , 'tooltipOptions.valueSuffix' ) ) translateElement ( null , serie . tooltipOptions , 'valueSuffix' ) ; if ( checkPath ( serie , 'options.tooltip.valueSuffix' ) ) translateElement ( null , serie . options . tooltip , 'valueSuffix' ) ; } ) ; if ( chart . rangeSelector ) { $ . each ( chart . rangeSelector . buttonOptions , function ( index , buttonOpt ) { translateElement ( null , buttonOpt , 'text' ) ; translateElement ( null , buttonOpt , 'title' ) ; chart . rangeSelector . dropdown [ index + 1 ] . innerHTML = buttonOpt . title || buttonOpt . text ; } ) ; chart . rangeSelector . alignElements ( ) ; } }
translateChart(chartOrEvent)
Translate the different parts of a chart that is not
re-created on reset
translateChart ( chartOrEvent ) Translate the different parts of a chart that is not re - created on reset
//Translate menu-items in the export-menu but only when the fullscreen is not open //Translate valuePrefix amd valueSuffix of tooltips - both in original optiona and in shortcut version //Translate range-selector buttons and drop-down //Translate button //Translate options in select //Align elemnets (buttons and select) to update select