$(document).ready( function() { //clear priority if people reload the page or lost connection while a wizard was active $(hyperion).one("cmd-config-getschema", function(event) { if(getStorage("wizardactive") === 'true') requestPriorityClear(); setStorage("wizardactive", false); }); function resetWizard() { $("#wizard_modal").modal('hide'); clearInterval(colorIntveralId); requestPriorityClear(); setStorage("wizardactive", false); $('#wizp1').toggle(true); $('#wizp2').toggle(false); } //rgb byte order wizard var colorIntveralId; var new_rgb_order; function changeColor() { var color = $("#wiz_canv_color").css('background-color'); if (color == 'rgb(255, 0, 0)') { $("#wiz_canv_color").css('background-color','rgb(0, 255, 0)'); requestSetColor('0','255','0'); } else { $("#wiz_canv_color").css('background-color','rgb(255, 0, 0)'); requestSetColor('255','0','0'); } } function startWizardRGB() { //create html $('#wiz_header').html(''+$.i18n('wiz_rgb_title')); $('#wizp1_body').html('
'+$.i18n('wiz_rgb_intro1')+'
'+$.i18n('wiz_rgb_intro2')+'
'); $('#wizp1_footer').html(''); $('#wizp2_body').html(''+$.i18n('wiz_rgb_expl')+'
'); $('#wizp2_body').append('