Changeset 5935 for extensions/AMetaData/amd_root.class.inc.php
- Timestamp:
- Apr 21, 2010, 9:27:51 PM (14 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
extensions/AMetaData/amd_root.class.inc.php
r5790 r5935 21 21 if (!defined('PHPWG_ROOT_PATH')) { die('Hacking attempt!'); } 22 22 23 include_once(PHPWG_PLUGINS_PATH.' grum_plugins_classes-2/common_plugin.class.inc.php');24 include_once(PHPWG_PLUGINS_PATH.' grum_plugins_classes-2/css.class.inc.php');23 include_once(PHPWG_PLUGINS_PATH.'GrumPluginClasses/classes/CommonPlugin.class.inc.php'); 24 include_once(PHPWG_PLUGINS_PATH.'GrumPluginClasses/classes/GPCCss.class.inc.php'); 25 25 26 26 include_once('amd_jpegmetadata.class.inc.php'); … … 28 28 include_once(JPEG_METADATA_DIR."TagDefinitions/XmpTags.class.php"); 29 29 30 class AMD_root extends common_plugin30 class AMD_root extends CommonPlugin 31 31 { 32 32 protected $css; //the css object … … 36 36 { 37 37 global $user; 38 $this-> plugin_name="AMetaData";39 $this-> plugin_name_files="amd";38 $this->setPluginName("AMetaData"); 39 $this->setPluginNameFiles("amd"); 40 40 parent::__construct($prefixeTable, $filelocation); 41 41 42 42 $tableList=array('used_tags', 'images_tags', 'images', 'selected_tags', 'groups_names', 'groups'); 43 $this->set _tables_list($tableList);44 45 $this->css = new css(dirname($this->filelocation).'/'.$this->plugin_name_files.".css");43 $this->setTablesList($tableList); 44 45 $this->css = new GPCCss(dirname($this->getFileLocation()).'/'.$this->getPluginNameFiles().".css"); 46 46 $this->jpegMD=new AMD_JpegMetaData(); 47 47 … … 64 64 --------------------------------------------------------------------------- */ 65 65 66 /* this function initialize var $ my_config with default values */67 public function init _config()68 { 69 $this-> my_config=array(66 /* this function initialize var $config with default values */ 67 public function initConfig() 68 { 69 $this->config=array( 70 70 'amd_NumberOfItemsPerRequest' => 25, 71 71 'amd_GetListTags_OrderType' => "tag", … … 79 79 } 80 80 81 public function load _config()82 { 83 parent::load _config();84 } 85 86 public function init _events()87 { 88 parent::init _events();81 public function loadConfig() 82 { 83 parent::loadConfig(); 84 } 85 86 public function initEvents() 87 { 88 parent::initEvents(); 89 89 90 90 91 91 if(!isset($_REQUEST['ajaxfct']) and 92 $this-> my_config['amd_FillDataBaseContinuously']=='y' and93 $this-> my_config['amd_AllPicturesAreAnalyzed']=='n')92 $this->config['amd_FillDataBaseContinuously']=='y' and 93 $this->config['amd_AllPicturesAreAnalyzed']=='n') 94 94 { 95 95 /* do analyze for a random picture only if : … … 270 270 while($row=mysql_fetch_assoc($result)) 271 271 { 272 $this-> my_config['amd_AllPicturesAreAnalyzed']=($row['nb']==0)?'y':'n';273 } 274 275 } 276 $this->save _config();272 $this->config['amd_AllPicturesAreAnalyzed']=($row['nb']==0)?'y':'n'; 273 } 274 275 } 276 $this->saveConfig(); 277 277 } 278 278
Note: See TracChangeset
for help on using the changeset viewer.