SVN: r22900 - trunk/quixote/form2
Neil Schemenauer <nascheme-fVcApmY9cLvQ3/1i3zOLAti2O/[email protected]> Tue, 28 Oct 2003 10:13:02 -0500
| Newsgroups | gmane.comp.web.quixote.cvs |
|---|---|
| Message-ID | <[email protected]> |
Author: nascheme
Date: 2003-10-28 10:13:02 -0500 (Tue, 28 Oct 2003)
New Revision: 22900
Modified:
trunk/quixote/form2/__init__.py
trunk/quixote/form2/form.py
trunk/quixote/form2/widget.py
Log:
Remove 'allowed_values' and 'description' parameters from SelectWidget.
Set svn:keywords property.
Property changes on: trunk/quixote/form2/__init__.py
___________________________________________________________________
Name: svn:keywords
+ form.py
Property changes on: trunk/quixote/form2/form.py
___________________________________________________________________
Name: svn:keywords
+ __init__.py
Modified: trunk/quixote/form2/widget.py
===================================================================
--- trunk/quixote/form2/widget.py 2003-10-27 22:34:12 UTC (rev 22899)
+++ trunk/quixote/form2/widget.py 2003-10-28 15:13:02 UTC (rev 22900)
@@ -224,26 +224,14 @@
"""
def __init__(self, name, value=None,
- allowed_values=None,
- descriptions=None,
options=None,
size=None,
sort=True,
verify_selection=True):
assert self.__class__ is not SelectWidget, "abstract class"
self.options = []
- # if options passed, cannot pass allowed_values or descriptions
- if allowed_values is not None:
- assert options is None, (
- 'cannot pass both allowed_values and options')
- assert allowed_values, (
- 'cannot pass empty allowed_values list')
- self.set_allowed_values(allowed_values, descriptions, sort)
- elif options is not None:
- assert descriptions is None, (
- 'cannot pass both options and descriptions')
- assert options, (
- 'cannot pass empty options list')
+ if options is not None:
+ assert options, 'cannot pass empty options list'
self.set_options(options, sort)
self.verify_selection = verify_selection
self.size = size
Property changes on: trunk/quixote/form2/widget.py
___________________________________________________________________
Name: svn:keywords
+ __init__.py