[geeklog-cvs] geeklog: More CUSTOM_ function support; ensure PLG_ functions ar...

geeklog-cvs at lists.geeklog.net geeklog-cvs at lists.geeklog.net
Sun Mar 29 15:53:26 EDT 2009


details:   http://project.geeklog.net/cgi-bin/hgweb.cgi/rev/65e07783f408
changeset: 6870:65e07783f408
user:      Dirk Haun <dirk at haun-online.de>
date:      Sun Mar 29 16:42:32 2009 +0200
description:
More CUSTOM_ function support; ensure PLG_ functions are called first

diffstat:

1 file changed, 16 insertions(+), 7 deletions(-)
system/lib-plugins.php |   23 ++++++++++++++++-------

diffs (64 lines):

diff -r fcec3e4bbb06 -r 65e07783f408 system/lib-plugins.php
--- a/system/lib-plugins.php	Sun Mar 29 13:31:43 2009 +0200
+++ b/system/lib-plugins.php	Sun Mar 29 16:42:32 2009 +0200
@@ -1446,15 +1446,15 @@
 {
     global $_PLUGINS;
 
-    if (function_exists ('CUSTOM_templateSetVars')) {
-        CUSTOM_templatesetvars($templatename, $template);
-    }
-
     foreach ($_PLUGINS as $pi_name) {
         $function = 'plugin_templatesetvars_' . $pi_name;
         if (function_exists($function)) {
             $function ($templatename, $template);
         }
+    }
+
+    if (function_exists('CUSTOM_templateSetVars')) {
+        CUSTOM_templatesetvars($templatename, $template);
     }
 }
 
@@ -2142,14 +2142,15 @@
 {
     global $_PLUGINS;
 
-    if (function_exists ('CUSTOM_runScheduledTask')) {
-        CUSTOM_runScheduledTask();
-    }
     foreach ($_PLUGINS as $pi_name) {
         $function = 'plugin_runScheduledTask_' . $pi_name;
         if (function_exists ($function)) {
             $function ();
         }
+    }
+
+    if (function_exists('CUSTOM_runScheduledTask')) {
+        CUSTOM_runScheduledTask();
     }
 }
 
@@ -2183,6 +2184,10 @@
         }
     }
 
+    if (function_exists('CUSTOM_itemsaved')) {
+        CUSTOM_itemsaved($id, $type, $old_id);
+    }
+
     return false; // for backward compatibility
 }
 
@@ -2211,6 +2216,10 @@
                 $function($id, $type);
             }
         }
+    }
+
+    if (function_exists('CUSTOM_itemdeleted')) {
+        CUSTOM_itemdeleted($id, $type);
     }
 }
 



More information about the geeklog-cvs mailing list