From 1835d2ae580525603308206f7b8e6b4552b3ca0f Mon Sep 17 00:00:00 2001 From: krzys-h Date: Fri, 27 Jun 2014 19:50:09 +0200 Subject: Removed old code based on #ifs (issue #55) --- src/ui/color.cpp | 34 +--------------------------------- 1 file changed, 1 insertion(+), 33 deletions(-) (limited to 'src/ui/color.cpp') diff --git a/src/ui/color.cpp b/src/ui/color.cpp index cbbc0dc..d1dc746 100644 --- a/src/ui/color.cpp +++ b/src/ui/color.cpp @@ -141,38 +141,7 @@ void CColor::Draw() m_engine->SetTexture("button1.png"); m_engine->SetState(Gfx::ENG_RSTATE_NORMAL); CControl::Draw(); - -#if _TEEN -// color = GetColor(m_color); - color = GetColor(); - - m_engine->SetTexture(""); // no texture - m_engine->SetState(Gfx::ENG_RSTATE_NORMAL); - - device = m_engine->GetDevice(); - - p1.x = m_pos.x + (4.0f / 640.0f); - p1.y = m_pos.y + (4.0f / 480.0f); - p2.x = m_pos.x + m_dim.x - (4.0f / 640.0f); - p2.y = m_pos.y + m_dim.y - (4.0f / 480.0f); - vertex[0] = Gfx::Vertex(Math::Vector(p1.x, p1.y, 0.0f), 0x00000000,0x00000000, Math::Point( 0.0f, 0.0f)); - vertex[1] = Gfx::Vertex(Math::Vector(p1.x, p2.y, 0.0f), 0x00000000,0x00000000, Math::Point( 0.0f, 0.0f)); - vertex[2] = Gfx::Vertex(Math::Vector(p2.x, p1.y, 0.0f), 0x00000000,0x00000000, Math::Point( 0.0f, 0.0f)); - vertex[3] = Gfx::Vertex(Math::Vector(p2.x, p2.y, 0.0f), 0x00000000,0x00000000, Math::Point( 0.0f, 0.0f)); - device->DrawPrimitive(Gfx::PRIMITIVE_TRIANGLE_STRIP, vertex, 4); - - p1.x = m_pos.x + (5.0f / 640.0f); - p1.y = m_pos.y + (5.0f / 480.0f); - p2.x = m_pos.x + m_dim.x - (5.0f / 640.0f); - p2.y = m_pos.y + m_dim.y - (5.0f / 480.0f); - vertex[0] = Gfx::Vertex(Math::Vector(p1.x, p1.y, 0.0f), color,0x00000000, Math::Point( 0.0f, 0.0f)); - vertex[1] = Gfx::Vertex(Math::Vector(p1.x, p2.y, 0.0f), color,0x00000000, Math::Point( 0.0f, 0.0f)); - vertex[2] = Gfx::Vertex(Math::Vector(p2.x, p1.y, 0.0f), color,0x00000000, Math::Point( 0.0f, 0.0f)); - vertex[3] = Gfx::Vertex(Math::Vector(p2.x, p2.y, 0.0f), color,0x00000000, Math::Point( 0.0f, 0.0f)); - device->DrawPrimitive(Gfx::PRIMITIVE_TRIANGLE_STRIP, vertex, 4); - - m_engine->AddStatisticTriangle(4); -#else + p1.x = m_pos.x + (3.0f / 640.0f); p1.y = m_pos.y + (3.0f / 480.0f); p2.x = m_pos.x + m_dim.x - (3.0f / 640.0f); @@ -191,7 +160,6 @@ void CColor::Draw() device = m_engine->GetDevice(); device->DrawPrimitive(Gfx::PRIMITIVE_TRIANGLE_STRIP, vertex, 4); m_engine->AddStatisticTriangle(2); -#endif } -- cgit v1.2.3-1-g7c22