[Zope3-checkins] CVS: Zope3/src/zope/schema/tests - states.py:1.5

Stephan Richter srichter at cosmos.phy.tufts.edu
Sat Apr 24 19:21:03 EDT 2004


Update of /cvs-repository/Zope3/src/zope/schema/tests
In directory cvs.zope.org:/tmp/cvs-serv31089/src/zope/schema/tests

Modified Files:
	states.py 
Log Message:


Cleanup.



Use Choice instead of Vocabulary Fields.




=== Zope3/src/zope/schema/tests/states.py 1.4 => 1.5 ===
--- Zope3/src/zope/schema/tests/states.py:1.4	Tue Jul 15 12:54:15 2003
+++ Zope3/src/zope/schema/tests/states.py	Sat Apr 24 19:21:02 2004
@@ -11,12 +11,13 @@
 # FOR A PARTICULAR PURPOSE.
 #
 ##############################################################################
+"""Sample vocabulary supporting state abbreviations.
 
-"""Sample vocabulary supporting state abbreviations."""
-
-from zope.schema import interfaces
-from zope.schema import vocabulary
+$Id$
+"""
 from zope.interface import implements
+from zope.schema import interfaces
+from zope.schema import Choice
 
 # This table is based on information from the United States Postal Service:
 # http://www.usps.com/ncsc/lookups/abbreviations.html#states
@@ -122,7 +123,7 @@
         return _states[value]
 
 
-class StateSelectionField(vocabulary.VocabularyField):
+class StateSelectionField(Choice):
 
     vocabulary = StateVocabulary()
 




More information about the Zope3-Checkins mailing list