/// <summary> /// Entry point of the plug in /// Write "toBabylon" in the Maya console to start it /// </summary> /// <param name="argl"></param> public override void doIt(MArgList argl) { MGlobal.displayInfo("Start Maya Plugin\n"); ExporterForm BabylonExport = new ExporterForm(); BabylonExport.Show(); BabylonExport.BringToFront(); BabylonExport.WindowState = FormWindowState.Normal; // DoExport(); }
/// <summary> /// Entry point of the plug in /// Write "toBabylon" in the Maya console to start it /// </summary> /// <param name="argl"></param> public override void doIt(MArgList argl) { if (form == null) { form = new ExporterForm(); } form.Show(); form.BringToFront(); form.WindowState = FormWindowState.Normal; form.closingByUser = () => { return(disposeForm()); }; // TODO - save states - FORM: checkboxes and inputs. MEL: reselected meshes / nodes? form.closingByShutDown = () => { return(disposeForm()); }; // form.closingByCrash = () => { return disposeForm(); }; }
/// <summary> /// Entry point of the plug in /// Write "toBabylon" in the Maya console to start it /// </summary> /// <param name="argl"></param> public override void doIt(MArgList argl) { if (form == null) { form = new ExporterForm(); } form.Show(); form.BringToFront(); form.WindowState = FormWindowState.Normal; form.FormClosed += (object sender, FormClosedEventArgs e) => { if (form == null) { return; } form.Dispose(); form = null; }; }