cmds.evalDeferred(*cmds.OutlinerWindow())*


?? I remember it helped me in a case like this... but not sure if it will help 
you..


On Friday, September 21, 2012 6:30:42 PM UTC-5, Jesse Capper wrote:
>
> 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