// =========================================================================== // 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: 17 June 1997 // // // Description: // This implements the Selection Polygon Marking Menu. // global proc doSelectPolygonMM() { menuItem -rp "N" -label (uiRes("m_buildPolyMM.kVertices")) -c "selectMode -co; selectType -pv 1 -pe 0 -pf 0 -puv 0; select -cl;"; menuItem -rp "E" -label (uiRes("m_buildPolyMM.kEdges")) -c "selectMode -co; selectType -pv 0 -pe 1 -pf 0 -puv 0; select -cl;"; menuItem -rp "S" -label (uiRes("m_buildPolyMM.kFaces")) -c "selectMode -co; selectType -pv 0 -pe 0 -pf 1 -puv 0; select -cl;"; menuItem -rp "W" -label (uiRes("m_buildPolyMM.kUVs")) -c "selectMode -co; selectType -pv 0 -pe 0 -pf 0 -puv 1; select -cl;"; setParent -m ..; } global proc buildPolyMM() // // Creates a marking menu that allows the user // to select Polygon masks. It reuses // the name tempMM for the name of the menu, to // ensure that there's only one of these at // any one time. { if( `popupMenu -exists tempMM` ) { deleteUI tempMM; } global string $gSelect; setToolTo $gSelect; popupMenu -alt 1 -mm 1 -b 1 -aob 1 -p `findPanelPopupParent` -pmc "doSelectPolygonMM" tempMM; }