mirror of https://github.com/stella-emu/stella.git
fixed initial focus display
This commit is contained in:
parent
0532bc824a
commit
264eb5ea1a
|
@ -324,6 +324,7 @@ void EventHandler::handleSystemEvent(SystemEvent e, int, int)
|
||||||
case SystemEvent::WINDOW_EXPOSED:
|
case SystemEvent::WINDOW_EXPOSED:
|
||||||
case SystemEvent::WINDOW_RESIZED:
|
case SystemEvent::WINDOW_RESIZED:
|
||||||
//myOSystem.frameBuffer().update(true); // force full update
|
//myOSystem.frameBuffer().update(true); // force full update
|
||||||
|
// TODO: test and maybe force a render update instead
|
||||||
myOSystem.frameBuffer().update();
|
myOSystem.frameBuffer().update();
|
||||||
break;
|
break;
|
||||||
#ifdef BSPF_UNIX
|
#ifdef BSPF_UNIX
|
||||||
|
|
|
@ -476,17 +476,6 @@ void Dialog::drawDialog()
|
||||||
clearDirty();
|
clearDirty();
|
||||||
}
|
}
|
||||||
|
|
||||||
// Draw outlines for focused widgets
|
|
||||||
// Don't change focus, since this will trigger lost and received
|
|
||||||
// focus events
|
|
||||||
if(_focusedWidget)
|
|
||||||
{
|
|
||||||
_focusedWidget = Widget::setFocusForChain(this, getFocusList(),
|
|
||||||
_focusedWidget, 0, false);
|
|
||||||
// if(_focusedWidget)
|
|
||||||
// _focusedWidget->draw(); // make sure the highlight color is drawn initially
|
|
||||||
}
|
|
||||||
|
|
||||||
Widget* w = _firstWidget;
|
Widget* w = _firstWidget;
|
||||||
|
|
||||||
// Draw all children
|
// Draw all children
|
||||||
|
@ -498,6 +487,17 @@ void Dialog::drawDialog()
|
||||||
w->draw();
|
w->draw();
|
||||||
w = w->_next;
|
w = w->_next;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Draw outlines for focused widgets
|
||||||
|
// Don't change focus, since this will trigger lost and received
|
||||||
|
// focus events
|
||||||
|
if(_focusedWidget)
|
||||||
|
{
|
||||||
|
_focusedWidget = Widget::setFocusForChain(this, getFocusList(),
|
||||||
|
_focusedWidget, 0, false);
|
||||||
|
//if(_focusedWidget)
|
||||||
|
// _focusedWidget->draw(); // make sure the highlight color is drawn initially
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
|
// - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
|
||||||
|
|
|
@ -269,7 +269,7 @@ Widget* Widget::setFocusForChain(GuiObject* boss, WidgetArray& arr,
|
||||||
|
|
||||||
s.frameRect(x, y, w, h, onTop ? kDlgColor : kBGColorLo);
|
s.frameRect(x, y, w, h, onTop ? kDlgColor : kBGColorLo);
|
||||||
|
|
||||||
tmp->setDirty();
|
//tmp->setDirty();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -325,7 +325,7 @@ Widget* Widget::setFocusForChain(GuiObject* boss, WidgetArray& arr,
|
||||||
if (onTop)
|
if (onTop)
|
||||||
s.frameRect(x, y, w, h, kWidFrameColor, FrameStyle::Dashed);
|
s.frameRect(x, y, w, h, kWidFrameColor, FrameStyle::Dashed);
|
||||||
|
|
||||||
tmp->setDirty();
|
//tmp->setDirty();
|
||||||
|
|
||||||
return tmp;
|
return tmp;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue