Commits

cboos  committed 5261b0c

Merge all pending changes from 0.12-stable.

  • Participants
  • Parent commits 47fa438
  • Branches trunk

Comments (0)

Files changed (4)

 *~
 .*.sw[op]
 .svn
-.git
+.hg
 build
 dist
 Trac.egg-info

File trac/htdocs/js/expand_dir.js

     else { // rows are toplevel rows, this is the initial call
       var anchor = window.location.hash.substr(1);
       if (anchor)
-        autoexpand = anchor.split("/");
+        autoexpand = decodeURI(anchor).split("/");
     }
 
     var autoexpand_expander = null;

File trac/versioncontrol/api.py

             return href.changeset(resource.id, parent and parent.id or None)
         elif resource.realm == 'source':
             parent = resource.parent
-            return href.source(parent and parent.id or None, resource.id)
+            return href.browser(parent and parent.id or None, resource.id,
+                                rev=resource.version or None)
         elif resource.realm == 'repository':
-            return href.source(resource.id or None)
+            return href.browser(resource.id or None)
 
     def resource_exists(self, resource):
         if resource.realm == 'repository':

File trac/versioncontrol/tests/api.py

         res = Resource('source', '/trunk/src')
         self.assertEqual('path /trunk/src',
                          get_resource_description(self.env, res))
-        self.assertEqual('/trac.cgi/source/trunk/src',
+        self.assertEqual('/trac.cgi/browser/trunk/src',
                          get_resource_url(self.env, res, self.env.href))
 
         repo = Resource('repository', 'repo')
         res = Resource('source', '/trunk/src', parent=repo)
         self.assertEqual('path /trunk/src in repo',
                          get_resource_description(self.env, res))
-        self.assertEqual('/trac.cgi/source/repo/trunk/src',
+        self.assertEqual('/trac.cgi/browser/repo/trunk/src',
                          get_resource_url(self.env, res, self.env.href))
 
         repo = Resource('repository', 'repo')
         res = Resource('source', '/trunk/src', version=42, parent=repo)
         self.assertEqual('path /trunk/src@42 in repo',
                          get_resource_description(self.env, res))
-        self.assertEqual('/trac.cgi/source/repo/trunk/src',
+        self.assertEqual('/trac.cgi/browser/repo/trunk/src?rev=42',
                          get_resource_url(self.env, res, self.env.href))
 
 
         res = Resource('repository', 'testrepo')
         self.assertEqual('Repository testrepo',
                          get_resource_description(self.env, res))
-        self.assertEqual('/trac.cgi/source/testrepo',
+        self.assertEqual('/trac.cgi/browser/testrepo',
                          get_resource_url(self.env, res, self.env.href))