enthought/enaml — pull request #38 by rkern (2011-12-02 14:24:30+00:00)
Title: ENH: Allow one to set up a Component with a non-Enaml toolkit parent.

I'm not committed to the details here. Names of the `external_parent` trait and the `parent=` keyword to `Component.setup()` are up for revision. Does anyone have a good idea if the `external_parent` trait should be a `WeakRef` or not?

We don't have to keep a reference to it at all if we modify the `create()` API to take it as an argument (and modify the `setup()` implementation to pick the supplied parent or the `parent_widget()` otherwise). I lean towards the latter, but I didn't want to touch every widget without getting feedback first.

In any case, this lets me embed an Enaml Component as a Tasks DockPane without problems (PySide 1.0.8, OS X).