Permalink
Browse files

don't resize save buttons in the online save browser, fix selection b…

…ug in console
  • Loading branch information...
jacob1 committed Mar 25, 2014
1 parent 50bc126 commit 2e6b4242d6248749c4648e6fd49ba7dc38e60873
Showing with 5 additions and 8 deletions.
  1. +2 −2 src/gui/interface/Label.cpp
  2. +3 −6 src/gui/interface/SaveButton.cpp
@@ -346,8 +346,8 @@ void Label::updateSelection()
void Label::SetDisplayText(std::string newText)
{
displayText = newText;
tDisplayText = displayText;
ClearSelection();
displayText = tDisplayText = newText;
}
void Label::Draw(const Point& screenPos)
@@ -180,19 +180,16 @@ void SaveButton::Draw(const Point& screenPos)
g->fillrect(screenPos.X, screenPos.Y, Size.X, Size.Y, 100, 170, 255, 100);
}
scaleFactor = (Size.Y-25)/((float)YRES);
thumbBoxSize = ui::Point(((float)XRES)*scaleFactor, ((float)YRES)*scaleFactor);
if(thumbnail)
{
thumbBoxSize = ui::Point(thumbnail->Width, thumbnail->Height);
//thumbBoxSize = ui::Point(thumbnail->Width, thumbnail->Height);
if(save && save->id)
g->draw_image(thumbnail, screenPos.X-3+(Size.X-thumbBoxSize.X)/2, screenPos.Y+(Size.Y-21-thumbBoxSize.Y)/2, 255);
else
g->draw_image(thumbnail, screenPos.X+(Size.X-thumbBoxSize.X)/2, screenPos.Y+(Size.Y-21-thumbBoxSize.Y)/2, 255);
}
else
{
scaleFactor = (Size.Y-25)/((float)YRES);
thumbBoxSize = ui::Point(((float)XRES)*scaleFactor, ((float)YRES)*scaleFactor);
}
if(save)
{
if(save->id)

0 comments on commit 2e6b424

Please sign in to comment.