Exemplo n.º 1
0
            public void Execute(object parameter)
            {
                Document doc = acApp.DocumentManager.MdiActiveDocument;

                if (parameter is RibbonButton)
                {
                    RibbonButton button = parameter as RibbonButton;
                    var          AX     = new AddXref();
                    var          UX     = new UnloadXref();

                    switch (button.Text)
                    {
                    case ("Add"):
                        MC.AddXref();
                        break;

                    case ("Unload"):
                        MC.UnloadXRef();
                        break;

                    case ("Detach"):
                        MC.DetachXRef();
                        break;

                    case ("Purge multiple drawings"):
                        MC.PurgeDrawings();
                        break;

                    case ("This drawing"):
                        MC.LayerUpdateThisDrawing();
                        break;

                    case ("Multiple drawings"):
                        MC.LayerUpdate();
                        break;

                    case ("Change attribute value"):
                        MC.ChangeAttribute_dialog();
                        break;

                    case ("Select layer this drawing"):
                        MC.AddLayerThisDrawing();
                        break;

                    case ("Select layer xref"):
                        MC.AddLayerXref();
                        break;

                    case ("Edit layer config"):
                        MC.EditLayerConfig();
                        break;

                    case ("Top Down"):
                        MC.OneVportTopDown();
                        break;

                    case ("Generate Attribute List"):
                        MC.GetAllAttributes();
                        break;

                    case ("Adjust Cable Trays"):
                        MC.AdjustCableTrays();
                        break;

                    default:
                        break;
                    }
                }
            }