qtranslate-x.php 531 B

123456789101112131415161718192021
  1. <?php
  2. if ( ! defined( 'ABSPATH' ) ) {
  3. die( '-1' );
  4. }
  5. /**
  6. * @since 4.4 vendors initialization moved to hooks in autoload/vendors.
  7. *
  8. * Used to initialize plugin qtranslate vendor.
  9. */
  10. add_action( 'plugins_loaded', 'vc_init_vendor_qtranslatex' );
  11. function vc_init_vendor_qtranslatex() {
  12. if ( defined( 'QTX_VERSION' ) ) {
  13. require_once vc_path_dir( 'VENDORS_DIR', 'plugins/class-vc-vendor-qtranslate-x.php' );
  14. $vendor = new Vc_Vendor_QtranslateX();
  15. add_action( 'vc_after_set_mode', array(
  16. $vendor,
  17. 'load',
  18. ) );
  19. }
  20. }