Index: HexagonBase/includes/theme_hook_process.inc
===================================================================
RCS file: /cvs/drupal-contrib/contributions/themes/hexagon/HexagonBase/includes/Attic/theme_hook_process.inc,v
retrieving revision 1.1.2.5
retrieving revision 1.1.2.6
diff -u -p -r1.1.2.5 -r1.1.2.6
--- HexagonBase/includes/theme_hook_process.inc	27 May 2010 17:27:44 -0000	1.1.2.5
+++ HexagonBase/includes/theme_hook_process.inc	19 Oct 2010 15:56:26 -0000	1.1.2.6
@@ -1,5 +1,5 @@
 <?php
-// $Id: theme_hook_process.inc,v 1.1.2.5 2010/05/27 17:27:44 dvessel Exp $
+// $Id: theme_hook_process.inc,v 1.1.2.6 2010/10/19 15:56:26 dvessel Exp $
 
 
 /**
@@ -93,6 +93,24 @@ function hex_process_includes(&$variable
 }
 
 /**
+ * Check for template naming suggestions using underscores and add dashes for
+ * consistency. This will only run for theming hooks implemented as a template.
+ */
+function hex_re_process(&$variables, $hook) {
+  $suggestions = array();
+  foreach ($variables['template_files'] as $suggestion) {
+    $suggestions[] = $suggestion;
+    // If the underscore is the leading character, this will miss it. It's
+    // not a common occurence and doing a strict check of "!== FALSE" has
+    // a small performance penalty. This is good enough.
+    if (strpos($suggestion, '_')) {
+      $suggestions[] = str_replace('_', '-', $suggestion);
+    }
+  }
+  $variables['template_files'] = $suggestions;
+}
+
+/**
  * A replacement for theme_render_template(). Used mostly for theme owned hooks.
  * Module owned hooks will use this only in the following two cases:
  * 
