public Location getLocation(Shape from, Shape to){
		Location type = null;
		Rectangle recFrom,recTo;
		recFrom = from.getBounds();
		recTo = to.getBounds();
		if(recFrom.x == recTo.x){
			if(recFrom.y < recTo.y){
				type = Location.SOUTH;
			}else{
				type = Location.NORTH;
			}
		}
		if(recFrom.y == recTo.y){
			if(recFrom.x < recTo.x){
				type = Location.EAST;
			}else{
				type= Location.WEST;
			}
		}else{
			if(recTo.x < recFrom.x){
				if(recTo.y < recFrom.y){
					type = Location.NORTHWEST;
				}else{
					type = Location.SOUTHWEST;
				}
			}
			if(recTo.x > recFrom.x){
				if(recTo.y < recFrom.y){
					type = Location.NORTHEAST;
				}else{
					type = Location.SOUTHEAST;
				}
			}	
		}	
		return type;
	}