Log message for revision 78394: Small refactoring: actually wrap in the provider in provider.__parent__, which *usually* ends up being the view, unless the provider decides otherwise.
Changed: U Zope/branches/philikon-aq/lib/python/Products/Five/browser/providerexpression.py -=- Modified: Zope/branches/philikon-aq/lib/python/Products/Five/browser/providerexpression.py =================================================================== --- Zope/branches/philikon-aq/lib/python/Products/Five/browser/providerexpression.py 2007-07-27 21:10:18 UTC (rev 78393) +++ Zope/branches/philikon-aq/lib/python/Products/Five/browser/providerexpression.py 2007-07-27 21:30:50 UTC (rev 78394) @@ -41,10 +41,10 @@ if provider is None: raise cp_interfaces.ContentProviderLookupError(name) - # A content provider's context (__parent__) is the view, not - # the context object. + # Wrap the content provider's in its __parent__, whatever that + # may be (typically the view). if getattr(provider, '__of__', None) is not None: - provider = provider.__of__(view) + provider = provider.__of__(provider.__parent__) # Insert the data gotten from the context addTALNamespaceData(provider, econtext) _______________________________________________ Zope-Checkins maillist - Zope-Checkins@zope.org http://mail.zope.org/mailman/listinfo/zope-checkins