// =========================================================================== // 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. // =========================================================================== // // Procedure Name: // doRemoveBindingSet // // Description: // Remove a template binding set associated with a given container. // // Input Arguments: // $version: The version of this option box. Used to know how to // interpret the $args array. // // $args: // Version 1: no arguments // global proc doRemoveBindingSet( int $version, string $args[] ) // // { global string $gPinnedContainerForBindingSetCmd; // If the user invokes the operation from the // "Asset Editor", this global variable will be set. Otherwise, // use the selected container. // string $container = $gPinnedContainerForBindingSetCmd; // Reset global $gPinnedContainerForBindingSetCmd = ""; if ($container == "") { string $sel[] = `ls -sl -containers`; if (size($sel) > 0) { $container = $sel[0]; } else { $sel = `ls -sl`; $container = `container -q -findContainer $sel`; if (size($container) == 0) { error((uiRes("m_doRemoveBindingSet.kMustSelectContainer"))); } } } // Remove the binding set containerRemoveBindingSet($container, ""); }