Пример #1
0
 protected function _setup_data()
 {
     switch ($this->get_status()) {
         case 'normal':
             $this->add_container_extra_classes('note-normal');
             break;
         case 'info':
             $this->add_container_extra_classes('note-info');
             break;
         case 'warning':
             $this->add_container_extra_classes('note-warning');
             break;
         case 'error':
             $this->add_container_extra_classes('note-error');
             break;
         case 'success':
             $this->add_container_extra_classes('note-success');
             break;
         default:
             $this->add_container_extra_classes('note-normal');
             break;
     }
     $this->add_data('status', $this->get_status());
     parent::_setup_data();
 }
Пример #2
0
 protected function _setup_data()
 {
     $opt = array('format' => $this->get_format());
     $this->add_data('opt', VP_Util_Text::make_opt($opt));
     $this->add_data('opt_raw', $opt);
     parent::_setup_data();
 }
Пример #3
0
 protected function _setup_data()
 {
     $opt = array('use_external_plugins' => $this->use_external_plugins(), 'disabled_externals_plugins' => implode(',', $this->get_disabled_externals_plugins()), 'disabled_internals_plugins' => implode(',', $this->get_disabled_internals_plugins()));
     $this->add_data('opt', VP_Util_Text::make_opt($opt));
     $this->add_data('opt_raw', $opt);
     parent::_setup_data();
 }
Пример #4
0
 protected function _setup_data()
 {
     $opt = array();
     foreach (array_keys($this->_defaults) as $name) {
         if ($name === 'is_rtl') {
             $new_name = 'isRTL';
         } else {
             $new_name = $this->camelize($name);
         }
         $opt[$new_name] = $this->{$name};
     }
     $this->add_data('opt', $this->make_opt($opt));
     parent::_setup_data();
 }
Пример #5
0
 public function __construct()
 {
     parent::__construct();
 }
Пример #6
0
 protected function _setup_data()
 {
     $this->add_data('height', $this->get_height());
     parent::_setup_data();
 }
Пример #7
0
 protected function _setup_data()
 {
     $opt = array('mode' => $this->get_editor_mode(), 'theme' => $this->get_editor_theme());
     $this->add_data('opt', VP_Util_Text::make_opt($opt));
     parent::_setup_data();
 }
Пример #8
0
 protected function _setup_data()
 {
     parent::_setup_data();
     $this->add_single_data('head_info', 'items_binding', $this->get_items_binding());
     $this->add_data('items', $this->get_items());
 }
Пример #9
0
 public function __construct()
 {
     parent::__construct();
     $this->add_container_extra_classes('vp-checked-field');
 }
Пример #10
0
 public function _setup_data()
 {
     $preview = VP_Util_Res::get_preview_from_url($this->get_value());
     $this->add_data('preview', $preview);
     parent::_setup_data();
 }
Пример #11
0
 protected function _setup_data()
 {
     parent::_setup_data();
 }
Пример #12
0
 public function __construct()
 {
     parent::__construct();
     $this->add_attribute('class', 'vp-input input-large');
 }
Пример #13
0
 public function set_value($_value)
 {
     $_value = $this->validate_value($_value);
     parent::set_value($_value);
 }
Пример #14
0
 protected function _setup_data()
 {
     $opt = array('minDate' => $this->get_min_date(), 'maxDate' => $this->get_max_date(), 'dateFormat' => $this->get_format(), 'value' => $this->get_value());
     $this->add_data('opt', VP_Util_Text::make_opt($opt));
     parent::_setup_data();
 }
Пример #15
0
 public function _setup_data()
 {
     $preview = wp_get_attachment_image_src($this->get_value(), 'thumbnail');
     $this->add_data('preview', $preview[0]);
     parent::_setup_data();
 }