//========================================================================
// E3D library
//
// Support for deleting things with undo/redo
//
// AUTHOR:  Gabor Nagy
// DATE:    2026-Jul-29 14:14:09
//
// Copyright (C) 1996-2026 by Gabor Nagy. All rights reserved.
//========================================================================
#ifndef _E3D_Deleting_h
#define _E3D_Deleting_h



#if defined (__cplusplus) && (!(defined (__CPLUSLIBS)))
extern "C" {
#endif


// Undoable Operator for deleting Node Trees, Branches and Nodes
//
typedef struct
{
	EOperatorCore;

	EList(, EObjectAndIndex*, Hierarchies);  // Root Nodes of Hierarchies to be deleted
	EList(, E3dBranch*, Branches);           // RootNodes of Branches to be deleted
} E3dOperatorDelete;


extern EOperatorClass*  E3dOperatorDeleteVertices_class;

extern void    E3d_DeleteVerticesAddAffectedPolygons(E3dOperatorAddDeleteVertices* POperator);
extern void    E3d_DeleteVerticesAddAffectedEdges(E3dOperatorAddDeleteVertices* POperator);

extern void    E3dNew_DeleteVerticesAddAffectedPolygons(E3dOperatorEditMesh* POperator);
extern void    E3dNew_DeleteVerticesAddAffectedEdges(E3dOperatorEditMesh* POperator);

extern int     E3dMesh_DeleteComponents(E3dMesh* PMesh, EIndex* PEdgeIndices, const EIndex PEdgeIndices_Count, const EBool PCheckSelections,
 E3dOperatorEditMesh* POperatorEditMesh,  const char* PName,  EBool* PDeletingPolygonsR);


#if defined (__cplusplus) && (!(defined (__CPLUSLIBS)))
}	// Close scope of 'extern "C"' declaration
#endif

#endif	// _E3D_Deleting_h
