From 612615ce3b650ef5f093acf9553316b87ca66d7b Mon Sep 17 00:00:00 2001 From: erg Date: Mon, 8 Sep 2008 17:09:54 +0000 Subject: [PATCH] Re-do isIn() function to use agcontains() from cgraph. --- cmd/gvpr/actions.c | 17 ----------------- 1 file changed, 17 deletions(-) diff --git a/cmd/gvpr/actions.c b/cmd/gvpr/actions.c index fdf01e826..788c25b2a 100644 --- a/cmd/gvpr/actions.c +++ b/cmd/gvpr/actions.c @@ -382,23 +382,6 @@ Agedge_t *isEdge(Agraph_t* g, Agnode_t * t, Agnode_t * h, char *key) return agedge(g, t, h, key, 0); } -/* isIn: - * Return 1 if object objp is in subgraph gp. - */ -int isIn(Agraph_t * gp, Agobj_t * objp) -{ - if (!sameG(gp, objp, "isIn", 0)) - return 0; - switch (AGTYPE(objp)) { - case AGRAPH: - return (agparent((Agraph_t *) objp) == gp); - case AGNODE: - return (agidnode(gp, AGID(objp), 0) != 0); - default: - return (agsubedge(gp, (Agedge_t *) objp, 0) != 0); - } -} - /* addNode: * Insert node n into subgraph g. * Return image of n -- 2.40.0