Index: menutrails.module
===================================================================
RCS file: /cvs/drupal-contrib/contributions/modules/menutrails/menutrails.module,v
retrieving revision 1.4.2.24
diff -u -p -r1.4.2.24 menutrails.module
--- menutrails.module	16 Mar 2010 21:18:49 -0000	1.4.2.24
+++ menutrails.module	1 Sep 2010 13:59:10 -0000
@@ -353,11 +353,22 @@ function menutrails_token_values($type, 
       }
       $tokens['menu-trail-parents-path-raw'] = implode('/', $trail_raw);
       $tokens['menu-trail-parents-path'] = implode('/', $trail);
+      
+      if(module_exists('pathauto')) {
+        $trail_pathauto_cleaned = array();
+        foreach($trail as $trail_part) {
+          $trail_pathauto_cleaned[] = pathauto_cleanstring($trail_part);
+        }
+        $tokens['menu-trail-parents-pathauto-settings-applied-path'] = implode('/', $trail_pathauto_cleaned);
+      }
     }
     // Return NULL in case there is no trail.
     else {
       $tokens['menu-trail-parents-path-raw'] = NULL;
       $tokens['menu-trail-parents-path'] = NULL;
+      if (module_exists('pathauto')) {
+        $tokens['menu-trail-parents-pathauto-settings-applied-path'] = NULL;
+      }
     }
     return $tokens;
   }
@@ -367,6 +378,10 @@ function menutrails_token_list($type = '
   if ($type == 'node' || $type == 'all') {
     $tokens['menutrails']['menu-trail-parents-path-raw'] = t("The menu trail leading up to but NOT including the node -- RAW");
     $tokens['menutrails']['menu-trail-parents-path'] = t("The menu trail leading up to but NOT including the node");
+    if (module_exists('pathauto')) {
+      $tokens['menutrails']['menu-trail-parents-pathauto-settings-applied-path'] =
+        t("The menu trail leading up to but NOT including the node, with pathauto settings applied");
+    }
     return $tokens;
   }
 }
