// =========================================================================== // Copyright 2018 Autodesk, Inc. All rights reserved. // // Use of this software is subject to the terms of the Autodesk license // agreement provided at the time of installation or download, or which // otherwise accompanies this software in either electronic or hard copy form. // =========================================================================== // // // Creation Date: July 10, 1997 // // Procedure Name: // AEnewMulti // // Description Name; // Creates a channel box for a mulit attribute in the AE // // Input Value: // nodeName, attribute, attribute's UI name, changedCommand // // Return Value // This method returns an array of strings. The 0th element // in the array is the OUTERMOST layout created here. This will // be used later to delete these controls. The 1st element is // the selectionConnection used to attach the channel box to a // particular node. // // global proc string[] AEnewMulti( string $nodeName, string $attribute, string $attrUIName, string $changedCommand ) { global int $gTextColumnWidthIndex; global int $gChannelBoxWidgetWidthIndex; global int $gChannelBoxWidgetHeightIndex; setUITemplate -pushTemplate attributeEditorTemplate; $baseLayout = `frameLayout -l $attrUIName`; //outermost layout must be returned later $createdLayout = `columnLayout -adj true -vis false`; $createdConnection = `selectionConnection -p $createdLayout -obj $nodeName`; $createdChannelBox = `channelBox -mw $gChannelBoxWidgetWidthIndex -lw $gTextColumnWidthIndex -mh $gChannelBoxWidgetHeightIndex -mlc $createdConnection -p $createdLayout -fal {$attribute} -aem true`; setParent ..; columnLayout -e -vis true $createdLayout; setParent ..; setUITemplate -popTemplate; if ($changedCommand != "") { string $cmd = $changedCommand + " \"" + $nodeName + "\""; scriptJob -p $createdLayout -rp -ac ($nodeName + "." + $attribute) $cmd; } string $retval[2]; $retval[0] = $baseLayout; $retval[1] = $createdConnection; return $retval; }