///////////////////////////////////////////////////////////////////////////// // myEasyButtons.mel Version 1.0 by Andrew Osiow Copyright 2009 // // Simple demo script that creates a column of clickable buttons // ///////////////////////////////////////////////////////////////////////////// global proc myeasybuttons() {// creates my easy button interface // delete any old Crystalball window preferences if (`windowPref -ex myEasyButtonsWindow`) windowPref -remove myEasyButtonsWindow; // delete any old Crystalball window structures if (`window -ex myEasyButtonsWindow`) deleteUI myEasyButtonsWindow; // create a window structure string $myEasyButtonsWin = `window -title "Easy Buttons" -iconName "Easy Buttons" -rtf 1 -s 0 // resize to fit - no size gadget myEasyButtonsWindow`; // create Easy Button layout string $myEasyButtonsForm = `columnLayout -w 150 -h 110 `; // add some buttons button -width 150 -height 26 -label "Cube" -align "center" -command "CreatePolygonCube;" easyCubeButton; button -width 150 -height 26 -label "Ball" -command "CreatePolygonSphere;" easyBallButton; // display my easy buttons Window showWindow $myEasyButtonsWin; }