Ignore:
Timestamp:
Jun 24, 2012, 9:13:37 PM (12 years ago)
Author:
grum
Message:

feature:2642- compatibility with Piwigo 2.4

File:
1 edited

Legend:

Unmodified
Added
Removed
  • extensions/AMenuManager/amm_aip.class.inc.php

    r15366 r16006  
    5151                          l10n('g002_album'),
    5252                          $this->getAdminLink().'-album');
    53     $this->css = new GPCCss(dirname($this->getFileLocation()).'/'.$this->getPluginNameFiles().".css");
    5453  }
    5554
     
    7675
    7776    $template->assign('plugin', $template_plugin);
    78     $template->assign('token', get_pwg_token());
    79 
     77    GPCCore::setTemplateToken();
    8078
    8179    switch($_GET['tab'])
     
    105103  }
    106104
    107 
    108   /**
    109    * initialize events call for the plugin
    110    */
    111105  public function initEvents()
    112106  {
    113     add_event_handler('loc_end_page_header', array(&$this->css, 'applyCSS'));
    114     GPCCss::applyGpcCss();
    115   }
    116 
     107    parent::initEvents();
     108    add_event_handler('blockmanager_register_blocks', array(&$this, 'registerBlocks') );
     109  }
     110
     111
     112  public function loadCSS()
     113  {
     114    global $template;
     115
     116    parent::loadCSS();
     117    GPCCore::addUI('gpcCSS');
     118    GPCCore::addHeaderCSS('amm.css', 'plugins/'.$this->getDirectory().'/'.$this->getPluginNameFiles().".css");
     119    GPCCore::addHeaderCSS('amm.cssT', 'plugins/'.$this->getDirectory().'/'.$this->getPluginNameFiles().'_'.$template->get_themeconf('name').".css");
     120  }
    117121
    118122  /**
Note: See TracChangeset for help on using the changeset viewer.