/**
  * If the file userinterface.js , enqueue it.
  */
 function enqueue_ui_javascript()
 {
     $this->js_requirements = array_merge($this->js_requirements, array('csl_script'));
     if (file_exists($this->addon->dir . 'include/userinterface.js')) {
         wp_enqueue_script($this->addon->slug . '_userinterface', $this->addon->url . '/include/userinterface.js', $this->js_requirements);
         wp_localize_script($this->addon->slug . '_userinterface', preg_replace('/\\W/', '', $this->addon->get_meta('TextDomain')) . '_settings', $this->js_settings);
     }
 }
 /**
  * Save settings from the UX tab.
  *
  * Set $this->admin_checkboxes with all the expected checkbox names then call parent::save_ux_settings.
  */
 function save_ux_settings()
 {
     array_walk($_POST, array($this, 'set_ValidOptions'));
     $this->options = $this->slplus->AdminUI->save_SerializedOption($this->addon->option_name, $this->addon->options, $this->admin_checkboxes);
     $this->addon->init_options();
 }