Skip to content

Commit

Permalink
Allow Deferred as kwarg to .display().
Browse files Browse the repository at this point in the history
  • Loading branch information
ralphbean committed Jul 11, 2012
1 parent 284c66a commit d4c6dcf
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions tw2/core/widgets.py
Original file line number Diff line number Diff line change
Expand Up @@ -396,6 +396,11 @@ def display(self, cls, value=None, displays_on=None, **kw):
else:
self = cls.req(**kw)

# Register any deferred params that are handed to us late in the game
# (after post_define). The .prepare method handles processing them
# later.
self._deferred += [k for k, v in kw.items() if isinstance(v, pm.Deferred)]

if not self.parent:
self.prepare()

Expand Down

0 comments on commit d4c6dcf

Please sign in to comment.