Changeset 7842 for main/waeup.kofa/trunk


Ignore:
Timestamp:
12 Mar 2012, 10:22:50 (13 years ago)
Author:
uli
Message:

Remove trash.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • main/waeup.kofa/trunk/src/waeup/kofa/widgets/phonewidget.py

    r7840 r7842  
    248248        return self.template()
    249249
    250 from zope.formlib.objectwidget import ObjectWidget
    251 from zope.schema import Object
    252 from waeup.kofa.widgets.objectwidget import KofaObjectWidget, ObjectWidgetView
    253250from zc.sourcefactory.contextual import BasicContextualSourceFactory
    254 
    255 
    256 
    257 class KofaPhoneWidgetView(ObjectWidgetView):
    258     template = ViewPageTemplateFile('phonewidget2.pt')
    259 
    260 class PhoneWidget2(KofaObjectWidget):
    261 
    262     _fake_value = None
    263 
    264     def __init__(self, context, request, **kw):
    265         self._fake_context = Object(IPhoneData, __name__=context.__name__)
    266         super(PhoneWidget2, self).__init__(
    267             self._fake_context, request, PhoneWidgetData, **kw)
    268         return
    269 
    270     def _to_fake_value(value):
    271         return PhoneWidgetData(None, value.number)
    272 
    273     def _from_fake_value(value):
    274         return value.number
    275 
    276     def _getView(self, request):
    277         return KofaPhoneWidgetView(self, request)
    278 
    279251from zope.formlib.textwidgets import TextWidget, renderElement
    280252from zope.component import getUtility
Note: See TracChangeset for help on using the changeset viewer.