[Zope3-checkins]
SVN: Zope3/trunk/src/zope/app/traversing/browser/absoluteurl.py
Stubbed out a protected method for subclasses to provide an
alternate context name. One use case is to provide names for
views that contain '@@' for traversal.
Garrett Smith
garrett at mojave-corp.com
Mon Nov 8 11:25:37 EST 2004
Log message for revision 28399:
Stubbed out a protected method for subclasses to provide an alternate context name. One use case is to provide names for views that contain '@@' for traversal.
Changed:
U Zope3/trunk/src/zope/app/traversing/browser/absoluteurl.py
-=-
Modified: Zope3/trunk/src/zope/app/traversing/browser/absoluteurl.py
===================================================================
--- Zope3/trunk/src/zope/app/traversing/browser/absoluteurl.py 2004-11-08 14:54:48 UTC (rev 28398)
+++ Zope3/trunk/src/zope/app/traversing/browser/absoluteurl.py 2004-11-08 16:25:36 UTC (rev 28399)
@@ -55,7 +55,7 @@
raise TypeError, _insufficientContext
url = str(getView(container, 'absolute_url', request))
- name = getattr(context, '__name__', None)
+ name = self._getContextName(context)
if name is None:
raise TypeError, _insufficientContext
@@ -66,6 +66,9 @@
__call__ = __str__
+ def _getContextName(self, context):
+ return getattr(context, '__name__', None)
+
def breadcrumbs(self):
context = self.context
request = self.request
More information about the Zope3-Checkins
mailing list