[Checkins] SVN: zc.comment/trunk/src/zc/comment/browser/widget.py Add a __call__ method to the Input widget to fix the error caused by the

Jacob Holm jh at improva.dk
Tue Mar 6 15:46:27 EST 2007


Log message for revision 73021:
  Add a __call__ method to the Input widget to fix the error caused by the
  change to zope.app.form in revision 72946.
  
  

Changed:
  U   zc.comment/trunk/src/zc/comment/browser/widget.py

-=-
Modified: zc.comment/trunk/src/zc/comment/browser/widget.py
===================================================================
--- zc.comment/trunk/src/zc/comment/browser/widget.py	2007-03-06 19:56:48 UTC (rev 73020)
+++ zc.comment/trunk/src/zc/comment/browser/widget.py	2007-03-06 20:46:26 UTC (rev 73021)
@@ -59,6 +59,18 @@
             value = p.get_data()
         return value
 
+    def __call__(self):
+        return zope.app.form.browser.widget.renderElement(
+            "textarea",
+            name=self.name,
+            id=self.name,
+            cssClass=self.cssClass,
+            rows=self.height,
+            cols=self.width,
+            style=self.style,
+            contents=self._getFormValue(), # already escaped
+            extra=self.extra,
+            )
 
 class Display(zope.app.form.browser.widget.DisplayWidget):
 



More information about the Checkins mailing list