addCptSupport(); $this->initComponents(); /** * Elementor init. * * Fires on Elementor init, after Elementor has finished loading but * before any headers are sent. * * @since 1.0.0 */ do_action('elementor/init'); \Hook::exec('actionCreativeElementsInit'); } // public function onRestApiInit(); /** * Init components. * * Initialize Elementor components. Register actions, run setting manager, * initialize all the components that run elementor, and if in admin page * initialize admin components. * * @since 1.0.0 * @access private */ private function initComponents() { // $this->inspector = new Inspector(); // $this->debugger = $this->inspector; SettingsManager::run(); $this->db = new DB(); $this->controls_manager = new ControlsManager(); $this->documents = new DocumentsManager(); $this->schemes_manager = new SchemesManager(); $this->elements_manager = new ElementsManager(); $this->widgets_manager = new WidgetsManager(); $this->skins_manager = new SkinsManager(); $this->files_manager = new FilesManager(); // $this->settings = new Settings(); // $this->tools = new Tools(); $this->editor = new Editor(); $this->preview = new Preview(); $this->frontend = new Frontend(); $this->templates_manager = new TemplateLibraryXManager(); // $this->maintenance_mode = new MaintenanceMode(); $this->dynamic_tags = new DynamicTagsManager(); $this->modules_manager = new ModulesManager(); // $this->role_manager = new Core\RoleManager\Role_Manager(); // $this->system_info = new System_Info\Main(); $this->revisions_manager = new RevisionsManager(); User::init(); Api::init(); // Tracker::init(); // $this->upgrade = new Core\Upgrade\Manager(); if (is_admin()) { $this->heartbeat = new Heartbeat(); // $this->wordpress_widgets_manager = new WordPressWidgetsManager(); // $this->admin = new Admin(); // $this->beta_testers = new BetaTesters(); // if (Utils::isAjax()) { // new ImagesManager(); // } $this->initCommon(); } } /** * @since 2.3.0 * @access public */ public function initCommon() { $this->common = new CommonApp(); $this->common->initComponents(); } // private function addCptSupport() /** * Register autoloader. * * Elementor autoloader loads all the classes needed to run the plugin. * * @since 1.6.0 * @access private */ private function registerAutoloader() { require _CE_PATH_ . '/includes/autoloader.php'; Autoloader::run(); } /** * Plugin constructor. * * Initializing Elementor plugin. * * @since 1.0.0 * @access private */ private function __construct() { $this->registerAutoloader(); // $this->logger = LogManager::instance(); // Maintenance::init(); // Compatibility::registerActions(); add_action('init', [$this, 'init'], 0); // add_action('rest_api_init', [$this, 'on_rest_api_init']); } }