I was checking out a question someone had on tech-artists and came across 
some behavior that I don't understand and hoped someone could enlighten me.
With the outliner closed, if I run:

*cmds.OutlinerWindow()*
*print cmds.getPanel(vis=True)*

cmds.getPanel doesn't contain the newly visible outliner. If I call 
OutlinerWindow() twice, and then getPanel:

*cmds.OutlinerWindow()*
*cmds.OutlinerWindow() 
*
*print cmds.getPanel(vis=True)*

cmds.getPanel will now contain the newly visible outliner. I tried using 
time.sleep, but that didn't help.
If I execute cmds.OutlinerWindow() by itself and then execute 
cmds.getPanel(vis=True), it will appear in the panel list. It's only when 
they are executed together that it doesn't appear in the panel list.

Anyone know why? Is there a better way to create the outliner?

-- 
view archives: http://groups.google.com/group/python_inside_maya
change your subscription settings: 
http://groups.google.com/group/python_inside_maya/subscribe

Reply via email to