Changeset 2954:85e45ee8f77e
- Timestamp:
- 02/03/15 09:32:32 (9 years ago)
- Branch:
- default
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
admin/plugins.php
r2566 r2954 181 181 ->setModules($modules) 182 182 ->displayModules( 183 /* cols */ array(' icon', 'name', 'distrib'),183 /* cols */ array('expander', 'icon', 'name', 'version', 'desc', 'distrib'), 184 184 /* actions */ array('activate', 'delete') 185 185 ); -
inc/core/class.dc.modules.php
r2945 r2954 26 26 protected $errors = array(); 27 27 protected $modules_names = array(); 28 protected $disabled_mode = false; 29 protected $disabled_meta = array(); 28 30 29 31 protected $id; … … 103 105 else 104 106 { 105 $this->disabled[$entry] = array( 106 'root' => $full_entry, 107 'root_writable' => is_writable($full_entry) 108 ); 107 if (file_exists($full_entry.'/_define.php')) { 108 $this->disabled_mode=true; 109 require $full_entry.'/_define.php'; 110 $this->disabled_mode=false; 111 $this->disabled[$entry] = $this->disabled_meta; 112 } 109 113 } 110 114 } … … 177 181 public function registerModule($name,$desc,$author,$version, $properties = array()) 178 182 { 183 if ($this->disabled_mode) { 184 $this->disabled_meta = array_merge( 185 $properties, 186 array( 187 'root' => $this->mroot, 188 'name' => $name, 189 'desc' => $desc, 190 'author' => $author, 191 'version' => $version, 192 'root_writable' => is_writable($this->mroot) 193 ) 194 ); 195 return; 196 } 179 197 # Fallback to legacy registerModule parameters 180 198 if (!is_array($properties)) { … … 195 213 'priority' => 1000, 196 214 'standalone_config' => false, 197 'type' => null 215 'type' => null, 216 'requires' => array() 198 217 ), $properties 199 218 );
Note: See TracChangeset
for help on using the changeset viewer.