void CSRAFView::Trace()
{
	CString caption;
	GetParent()->GetWindowText(caption);
	CBrush br(RGB(255,255,255));
	CDC* pDC = GetDC();
	CBrush* pOld = pDC->SelectObject(&br);

	if (caption == "Img1" || caption == "Img1r" || 
		caption == "Img1rg")
	{
		CRect cuadrado(15, 31, 106, 119);
		CRect triangulo(180, 10, 313, 141);
		CRect circulo(21, 171, 168, 307);
		CRect pentagono(282, 369 , 384, 487);
		CRect hexagono(236, 202, 410, 330);
		CRect rectangulo(38, 357, 171, 456);

		if (!m_imgList.Find("Cuadrado"))
			pDC->Rectangle(&cuadrado);

		if (!m_imgList.Find("Triangulo"))
			pDC->Rectangle(&triangulo);

		if (m_imgList.Find("Circulo"))
			pDC->Rectangle(&circulo);

		if (m_imgList.Find("Pentagono"))
			pDC->Rectangle(&pentagono);

		if (m_imgList.Find("Hexagono"))
			pDC->Rectangle(&hexagono);

		if (m_imgList.Find("Rectangulo"))
			pDC->Rectangle(&rectangulo);
	}
	/*else if (caption == "Img2" || caption == "Img2r" || 
		caption == "Img2rg")
	{
		CRect tenedor(219, 56, 263, 234);
		CRect cuchara(41, 29, 97, 240);
		CRect cuchillo(129, 31, 160, 238);
		CRect r1(8, 6 , 302, 13);
		CRect r2(8, 6 , 12, 261);
		CRect r3(6, 256 , 303, 260);
		CRect r4(295, 6 , 304, 260);

		if (tenedor.PtInRect(point) && m_imgList.Find("Tenedor"))
			ShowResult(point, "Tenedor", 50, 30);

		else if (cuchara.PtInRect(point) && m_imgList.Find("Cuchara"))
			ShowResult(point, "Cuchara", 50, 30);

		else if (cuchillo.PtInRect(point) && m_imgList.Find("Cuchillo"))
			ShowResult(point, "Cuchillo", 50, 30);

		else if (r1.PtInRect(point) && m_imgList.Find("Rectangulo"))
			ShowResult(point, "Rectangulo", 50, 30);

		else if (r2.PtInRect(point) && m_imgList.Find("Rectangulo"))
			ShowResult(point, "Rectangulo", 50, 30);

		else if (r3.PtInRect(point) && m_imgList.Find("Rectangulo"))
			ShowResult(point, "Rectangulo", 50, 30);

		else if (r4.PtInRect(point) && m_imgList.Find("Rectangulo"))
			ShowResult(point, "Rectangulo", 50, 30);
	}*/

	pDC->SelectObject(pOld);
}