static void * MyMoveViaLowLevel (DataType *Data, PinType *Via, Coord dx, Coord dy) { if (Data) { RestoreToPolygon (Data, VIA_TYPE, Via, Via); r_delete_entry (Data->via_tree, (BoxType *) Via); } MOVE_VIA_LOWLEVEL (Via, dx, dy); if (Data) { r_insert_entry (Data->via_tree, (BoxType *) Via, 0); ClearFromPolygon (Data, VIA_TYPE, Via, Via); } return Via; }
/* --------------------------------------------------------------------------- * moves a via */ static void * MoveVia (PinTypePtr Via) { r_delete_entry (PCB->Data->via_tree, (BoxType *)Via); RestoreToPolygon (PCB->Data, VIA_TYPE, Via, Via); MOVE_VIA_LOWLEVEL (Via, DeltaX, DeltaY); if (PCB->ViaOn) EraseVia (Via); r_insert_entry (PCB->Data->via_tree, (BoxType *)Via, 0); ClearFromPolygon (PCB->Data, VIA_TYPE, Via, Via); if (PCB->ViaOn) { DrawVia (Via); Draw (); } return (Via); }