version = '1.4.0'; $this->inc = trailingslashit( plugin_dir_path( __FILE__ ) . '/includes' ); $this->load_dependencies(); $this->launch(); } /** * Load the required dependencies for the plugin. * * - Admin loads the backend functionality * - Content Type registers the post_type and taxonomy * - Metaboxes loads the custom metabox * - Public provides front-end functionality * - Dashboard Glancer loads the helper class for the admin dashboard * * @since 1.4.0 */ private function load_dependencies() { require_once( $this->inc . 'class-arconix-portfolio-admin.php' ); require_once( $this->inc . 'class-arconix-portfolio-content-type.php' ); require_once( $this->inc . 'class-arconix-portfolio-metaboxes.php' ); require_once( $this->inc . 'class-arconix-portfolio-public.php' ); if ( ! class_exists( 'Gamajo_Dashboard_Glancer' ) ) require_once( $this->inc . 'class-gamajo-dashboard-glancer.php' ); } /** * Load all the necessary classes * * @since 1.4.0 */ private function launch() { new Arconix_Portfolio_Admin( $this->get_version() ); new Arconix_Portfolio_Content_Type(); new Arconix_Portfolio_Metaboxes(); } /** * Get the current version of the plugin * * @since 1.4.0 * @return string Plugin current version */ public function get_version() { return $this->version; } } /** Vroom vroom */ add_action( 'plugins_loaded', 'arconix_portfolio_gallery_run' ); function arconix_portfolio_gallery_run() { new Arconix_Portfolio_Gallery; }