provide Zope 2.9 compatibility for statful package
git-svn-id: svn://svn.cy55.de/Zope3/src/cybertools/trunk@2566 fd906abe-77d9-0310-91a1-e0d9ade77398
This commit is contained in:
parent
45f090341e
commit
3e6ac40962
2 changed files with 8 additions and 2 deletions
|
@ -26,7 +26,10 @@ from persistent.interfaces import IPersistent
|
||||||
from persistent.mapping import PersistentMapping
|
from persistent.mapping import PersistentMapping
|
||||||
from zope import component
|
from zope import component
|
||||||
from zope.component import adapts
|
from zope.component import adapts
|
||||||
|
try:
|
||||||
from zope.component.interfaces import ObjectEvent
|
from zope.component.interfaces import ObjectEvent
|
||||||
|
except ImportError: # Zope 2.9
|
||||||
|
from zope.app.event.objectevent import ObjectEvent
|
||||||
from zope.event import notify
|
from zope.event import notify
|
||||||
from zope.interface import implements
|
from zope.interface import implements
|
||||||
|
|
||||||
|
|
|
@ -22,7 +22,10 @@ Interfaces for the `stateful` package.
|
||||||
$Id$
|
$Id$
|
||||||
"""
|
"""
|
||||||
|
|
||||||
|
try:
|
||||||
from zope.component.interfaces import IObjectEvent
|
from zope.component.interfaces import IObjectEvent
|
||||||
|
except ImportError: # Zope 2.9
|
||||||
|
from zope.app.event.interfaces import IObjectEvent
|
||||||
from zope.interface import Interface, Attribute
|
from zope.interface import Interface, Attribute
|
||||||
|
|
||||||
|
|
||||||
|
|
Loading…
Add table
Reference in a new issue