'tab' key skips disabled widgets

'ghost' read traps are displayed by 'RTrapG'
This commit is contained in:
thrust26 2017-12-19 09:01:26 +01:00
parent b280a3ed27
commit d7a34ec7dd
3 changed files with 23 additions and 16 deletions

View File

@ -147,7 +147,8 @@ inline uInt8 M6502::peek(uInt16 address, uInt8 flags)
{ {
myJustHitReadTrapFlag = true; myJustHitReadTrapFlag = true;
stringstream msg; stringstream msg;
msg << "RTrap[" << Common::Base::HEX2 << cond << "]" << (myTrapCondNames[cond].empty() ? ": " : "If: {" + myTrapCondNames[cond] + "} "); msg << "RTrap" << (flags == DISASM_NONE ? "G[" : "[") << Common::Base::HEX2 << cond << "]"
<< (myTrapCondNames[cond].empty() ? ": " : "If: {" + myTrapCondNames[cond] + "} ");
myHitTrapInfo.message = msg.str(); myHitTrapInfo.message = msg.str();
myHitTrapInfo.address = address; myHitTrapInfo.address = address;
} }

View File

@ -248,7 +248,6 @@ void PopUpWidget::drawWidget(bool hilite)
// Fill the background // Fill the background
s.fillRect(x + 1, _y + 1, w - 17, _h - 2, kWidColor); s.fillRect(x + 1, _y + 1, w - 17, _h - 2, kWidColor);
s.fillRect(x + w - 15, _y + 2, 13, _h - 4, isEnabled() && hilite ? kWidColor : kBGColorHi); s.fillRect(x + w - 15, _y + 2, 13, _h - 4, isEnabled() && hilite ? kWidColor : kBGColorHi);
//s.vLine(x + w - 17, _y, _y + _h - 1, kShadowColor);
// Draw an arrow pointing down at the right end to signal this is a dropdown/popup // Draw an arrow pointing down at the right end to signal this is a dropdown/popup
s.drawBitmap(down_arrow, x + w - 13, _y + myArrowsY + 1, s.drawBitmap(down_arrow, x + w - 13, _y + myArrowsY + 1,
!isEnabled() ? kColor : kTextColor, 9u, 8u); !isEnabled() ? kColor : kTextColor, 9u, 8u);

View File

@ -241,24 +241,31 @@ Widget* Widget::setFocusForChain(GuiObject* boss, WidgetArray& arr,
return nullptr; return nullptr;
else else
{ {
switch(direction) int oldPos = pos;
do
{ {
case -1: // previous widget switch(direction)
pos--; {
if(pos < 0) case -1: // previous widget
pos = size - 1; pos--;
break; if(pos < 0)
pos = size - 1;
break;
case +1: // next widget case +1: // next widget
pos++; pos++;
if(pos >= size) if(pos >= size)
pos = 0; pos = 0;
break; break;
default: default:
// pos already set // pos already set
break;
}
// break if all widgets should be disabled
if(oldPos == pos)
break; break;
} } while(!arr[pos]->isEnabled());
} }
// Now highlight the active widget // Now highlight the active widget