I haven't been able to keep up with all the widget changes, and I am
starting to use them again for a new project. I am needing to have a
default value in a widget that can be changed as a parameter to
display() or render(). I thought I could do the following:
class MyWidget(Widget):
template = 'my.template.for.the.widget'
template_vars = ['defaulted_param']
defaulted_param = False
mywidget = MyWidget()
... and then when I used it, I could just do a `mywidget.display()'
and it would assume a value of False for defaulted_param, but I can
override this with `mywidget.display(defaulted_param=True)'.
Is this still the case? It doesn't seem to be working for me, or I
am misunderstanding widgets (again). I really can't wait for the
documentation sprint to be over, so I can finally fully grasp widgets ;)
Thanks.
--
Jonathan LaCour
http://cleverdevil.org
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"TurboGears" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at http://groups.google.com/group/turbogears
-~----------~----~----~----~------~----~------~--~---