I write the Full Version ! .... I am so tired >"<
CODE
global proc string[] JME_GetSel_SMT()
{
string $getSel[] = ls -l -sl
;
if(!size($getSel)){print("please Select a Object !\n");return{""};}
string $selDag[] = ls -l -s -dag -sl
;
string $getSG[],$getTmp[],$getMat[],$getChild[],$tmpA[],$tmpB[],$tmpC[],$getOpt="";
for($i in $selDag){
clear $tmpA;clear $tmpB;
$tmpB = connectionInfo -dfs ($i+".iog[0]")
;
if (size $tmpB
){
for($q in $tmpB){
string $buf[];clear $buf;
tokenize $q "." $buf;
$getTmp[size $getTmp
] = $buf[0];
}
}
$tmpA = listHistory $i
;
if (size $tmpA
){
for($q in $tmpA){
string $buf[];clear $buf;
tokenize $q "." $buf;
$getTmp[size $getTmp
] = $buf[0];
}
}
}
for($U in $getTmp){
if((nodeType $U
== "shadingEngine")||
(nodeType $U
== "FurDescription"))
{$getSG[size($getSG)]= $U;}
}
hyperShade -smn;clear $getTmp;
$getMat = stringArrayCatenate($getSG,ls -sl
);
for($i in $getMat){
$getOpt +=" -rhl "+ $i;
clear $tmpC;$tmpC = listHistory $i
;
for($c in $tmpC){
if(nodeType $c
=="file")
{$getOpt +=" -rhl "+ $c;$getTmp[size($getTmp)]=$c;}
}
}
$getMat = stringArrayCatenate($getMat,$getTmp);
tearOffPanel "Multilister" "multiListerPanel" true;
for($g=0;$g<10;$g++){
if(listerEditor -q -ex ("multiListerPanel1TopTab"+$g)
)
{eval("listerEditor -edit "+$getOpt+" multiListerPanel1TopTab"+$g);}
if(listerEditor -q -ex ("multiListerPanel1BottomTab"+$g)
)
{eval("listerEditor -edit "+$getOpt+" multiListerPanel1BottomTab"+$g);}
}
select $getSel;
return (stringArrayRemoveDuplicates($getMat));
}
JME_GetSel_SMT;