Changeset 2297663
- Timestamp:
- 05/04/2020 11:38:52 AM (6 years ago)
- Location:
- ultimate-elements-elementor-page-builder
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
ultimate-elements-elementor-page-builder/tags/2.0/ultimate-elements-elementor-page-builder.php
r2297654 r2297663 66 66 add_action( 'elementor/widgets/widgets_registered', array( $this, 'widgets_registered' ) ); 67 67 68 68 add_action( 'elementor/controls/controls_registered', array( $this, 'register_controls' ) ); 69 69 add_action( 'elementor/document/before_save', array( $this, 'elementor_save_data' ) , 10 ,2 ); 70 70 … … 74 74 75 75 wp_register_style('ueepb-front-style', UEEPB_PLUGIN_URL . 'css/ueepb-front.css'); 76 76 wp_enqueue_style( 'ueepb-front-style' ); 77 77 78 78 wp_register_script('ueepb-front', UEEPB_PLUGIN_URL.'js/ueepb-front.js', array('jquery')); … … 279 279 280 280 } 281 } 281 } 282 283 public function register_controls() { 284 285 $control_files = array('ueepb-select2-control.php' ); 286 287 foreach ($control_files as $control_file_item) { 288 $control_file = plugin_dir_path(__FILE__).'controls/'.$control_file_item; 289 $template_file = locate_template($control_file); 290 if ( !$template_file || !is_readable( $template_file ) ) { 291 $template_file = plugin_dir_path(__FILE__).'controls/'.$control_file_item; 292 } 293 294 if ( $template_file && is_readable( $template_file ) ) { 295 require_once $template_file; 296 } 297 } 298 299 $controls_manager = \Elementor\Plugin::$instance->controls_manager; 300 $controls_manager->register_control( 'ueepb_select2', new UEEPB_Select2() ); 301 302 } 282 303 283 304 public function elementor_save_data($document,$data) { } -
ultimate-elements-elementor-page-builder/trunk/ultimate-elements-elementor-page-builder.php
r2297654 r2297663 66 66 add_action( 'elementor/widgets/widgets_registered', array( $this, 'widgets_registered' ) ); 67 67 68 68 add_action( 'elementor/controls/controls_registered', array( $this, 'register_controls' ) ); 69 69 add_action( 'elementor/document/before_save', array( $this, 'elementor_save_data' ) , 10 ,2 ); 70 70 … … 74 74 75 75 wp_register_style('ueepb-front-style', UEEPB_PLUGIN_URL . 'css/ueepb-front.css'); 76 76 wp_enqueue_style( 'ueepb-front-style' ); 77 77 78 78 wp_register_script('ueepb-front', UEEPB_PLUGIN_URL.'js/ueepb-front.js', array('jquery')); … … 279 279 280 280 } 281 } 281 } 282 283 public function register_controls() { 284 285 $control_files = array('ueepb-select2-control.php' ); 286 287 foreach ($control_files as $control_file_item) { 288 $control_file = plugin_dir_path(__FILE__).'controls/'.$control_file_item; 289 $template_file = locate_template($control_file); 290 if ( !$template_file || !is_readable( $template_file ) ) { 291 $template_file = plugin_dir_path(__FILE__).'controls/'.$control_file_item; 292 } 293 294 if ( $template_file && is_readable( $template_file ) ) { 295 require_once $template_file; 296 } 297 } 298 299 $controls_manager = \Elementor\Plugin::$instance->controls_manager; 300 $controls_manager->register_control( 'ueepb_select2', new UEEPB_Select2() ); 301 302 } 282 303 283 304 public function elementor_save_data($document,$data) { }
Note: See TracChangeset
for help on using the changeset viewer.