// =========================================================================== // 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: 31 Oct 1996 // // Description: // Renaming dynamic attributes from a particle object. // // ========== dynUpdateRenameAttrWin ======= // // SYNOPSIS // This proc is called by a scriptJob when the selection // changes. If the dynAttr window is open, it updates it // to reflect the new selection. If the window is not open, // it kills the scriptJob to prevent unnecesary background // processing. // global proc dynUpdateRenameAttrWin() { global string $gRenameAttrWin; global int $gDynRenameAttrUpdateJob; if ( `window -exists $gRenameAttrWin` ){ if ( `window -q -visible $gRenameAttrWin` ){ dynRenameAttrWin( {} ); } else if ($gDynRenameAttrUpdateJob != 0) { evalDeferred("scriptJob -force -kill " + $gDynRenameAttrUpdateJob); $gDynRenameAttrUpdateJob = 0; } } }