Move rect border drawing for previewview to draw over fav+report buttons, fix issue #64

This commit is contained in:
Simon Robertshaw 2012-08-03 18:08:41 +01:00
parent 11d2b0eb3c
commit 9260b2c3e8

View File

@ -196,13 +196,6 @@ void PreviewView::DoDraw()
{
Window::DoDraw();
Graphics * g = ui::Engine::Ref().g;
if(c->GetDoOpen())
{
g->fillrect(Position.X+(Size.X/2)-101, Position.Y+(Size.Y/2)-26, 202, 52, 0, 0, 0, 210);
g->drawrect(Position.X+(Size.X/2)-100, Position.Y+(Size.Y/2)-25, 200, 50, 255, 255, 255, 180);
g->drawtext(Position.X+(Size.X/2)-(Graphics::textwidth("Loading save...")/2), Position.Y+(Size.Y/2)-5, "Loading save...", style::Colour::InformationTitle.Red, style::Colour::InformationTitle.Green, style::Colour::InformationTitle.Blue, 255);
}
for(int i = 0; i < commentTextComponents.size(); i++)
{
int linePos = commentTextComponents[i]->Position.Y+commentsPanel->ViewportPosition.Y+commentTextComponents[i]->Size.Y+4;
@ -214,6 +207,14 @@ void PreviewView::DoDraw()
Position.Y+linePos,
255, 255, 255, 100);
}
if(c->GetDoOpen())
{
g->fillrect(Position.X+(Size.X/2)-101, Position.Y+(Size.Y/2)-26, 202, 52, 0, 0, 0, 210);
g->drawrect(Position.X+(Size.X/2)-100, Position.Y+(Size.Y/2)-25, 200, 50, 255, 255, 255, 180);
g->drawtext(Position.X+(Size.X/2)-(Graphics::textwidth("Loading save...")/2), Position.Y+(Size.Y/2)-5, "Loading save...", style::Colour::InformationTitle.Red, style::Colour::InformationTitle.Green, style::Colour::InformationTitle.Blue, 255);
}
g->drawrect(Position.X, Position.Y, Size.X, Size.Y, 255, 255, 255, 255);
}
void PreviewView::OnDraw()
@ -222,7 +223,6 @@ void PreviewView::OnDraw()
//Window Background+Outline
g->clearrect(Position.X-2, Position.Y-2, Size.X+4, Size.Y+4);
g->drawrect(Position.X, Position.Y, Size.X, Size.Y, 255, 255, 255, 255);
//Save preview (top-left)
if(savePreview && savePreview->Data)