Some tweaks to onscreen message colours, to match the current scheme.

git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2332 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
This commit is contained in:
stephena 2012-01-03 20:52:45 +00:00
parent 11fe5f4da1
commit 06de98d05d
3 changed files with 6 additions and 8 deletions

View File

@ -302,7 +302,7 @@ void FrameBuffer::update()
// - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
void FrameBuffer::showMessage(const string& message, MessagePosition position,
bool force, uInt32 color)
bool force)
{
// Only show messages if they've been enabled
if(!(force || myOSystem->settings().getBool("uimessages")))
@ -318,7 +318,7 @@ void FrameBuffer::showMessage(const string& message, MessagePosition position,
// Precompute the message coordinates
myMsg.text = message;
myMsg.counter = uInt32(myOSystem->frameRate()) << 1; // Show message for 2 seconds
myMsg.color = color;
myMsg.color = kBtnTextColor;
myMsg.w = myOSystem->font().getStringWidth(myMsg.text) + 10;
myMsg.h = myOSystem->font().getFontHeight() + 8;
@ -416,8 +416,8 @@ inline void FrameBuffer::drawMessage()
}
myMsg.surface->setPos(myMsg.x + myImageRect.x(), myMsg.y + myImageRect.y());
myMsg.surface->fillRect(0, 0, myMsg.w-2, myMsg.h-4, kBGColor);
myMsg.surface->box(0, 0, myMsg.w, myMsg.h-2, kColor, kShadowColor);
myMsg.surface->fillRect(1, 1, myMsg.w-2, myMsg.h-2, kBtnColor);
myMsg.surface->box(0, 0, myMsg.w, myMsg.h, kColor, kShadowColor);
myMsg.surface->drawString(&myOSystem->font(), myMsg.text, 4, 4,
myMsg.w, myMsg.color, kTextAlignLeft);
myMsg.counter--;

View File

@ -140,12 +140,10 @@ class FrameBuffer
@param message The message to be shown
@param position Onscreen position for the message
@param force Force showing this message, even if messages are disabled
@param color Color of text in the message
*/
void showMessage(const string& message,
MessagePosition position = kBottomCenter,
bool force = false,
uInt32 color = kTextColorHi);
bool force = false);
/**
Toggles showing or hiding framerate statistics.

View File

@ -254,7 +254,7 @@ void Dialog::drawDialog()
{
// cerr << "Dialog::drawDialog(): w = " << _w << ", h = " << _h << " @ " << &s << endl << endl;
s.fillRect(_x+1, _y+1, _w-2, _h-2, kDlgColor);
s.fillRect(_x, _y, _w, _h, kDlgColor);
s.box(_x, _y, _w, _h, kColor, kShadowColor);
// Make all child widget dirty