mirror of https://github.com/stella-emu/stella.git
Fix minor warnings reported by gcc and clang.
This commit is contained in:
parent
2406b8ad0f
commit
a424b8b9a7
|
@ -635,12 +635,13 @@ void DataGridWidget::drawWidget(bool hilite)
|
|||
{
|
||||
if(_changedList[pos])
|
||||
{
|
||||
s.fillRect(x - 3, y - 1, _colWidth-1, _rowHeight-1, onTop ? kDbgChangedColor : _bgcolorlo);
|
||||
s.fillRect(x - 3, y - 1, _colWidth-1, _rowHeight-1,
|
||||
onTop ? uInt32(kDbgChangedColor) : _bgcolorlo);
|
||||
|
||||
if(_hiliteList[pos])
|
||||
textColor = kDbgColorHi;
|
||||
else
|
||||
textColor = onTop ? kDbgChangedTextColor : textColor;
|
||||
textColor = onTop ? uInt32(kDbgChangedTextColor) : textColor;
|
||||
}
|
||||
else if(_hiliteList[pos])
|
||||
textColor = kDbgColorHi;
|
||||
|
|
|
@ -96,7 +96,7 @@ void PromptWidget::drawWidget(bool hilite)
|
|||
else
|
||||
fgcolor = c >> 8;
|
||||
|
||||
s.drawChar(_font, c & 0x7f, x, y, onTop ? fgcolor : kColor);
|
||||
s.drawChar(_font, c & 0x7f, x, y, onTop ? fgcolor : uInt32(kColor));
|
||||
x += _kConsoleCharWidth;
|
||||
}
|
||||
y += _kConsoleLineHeight;
|
||||
|
|
|
@ -514,7 +514,7 @@ void RomListWidget::drawWidget(bool hilite)
|
|||
|
||||
// Draw labels
|
||||
s.drawString(_font, dlist[pos].label, xpos, ypos, _labelWidth,
|
||||
dlist[pos].hllabel ? textColor : kColor);
|
||||
dlist[pos].hllabel ? textColor : uInt32(kColor));
|
||||
|
||||
// Bytes are only editable if they represent code, graphics, or accessible data
|
||||
// Otherwise, the disassembly should get all remaining space
|
||||
|
|
|
@ -115,11 +115,13 @@ void ToggleBitWidget::drawWidget(bool hilite)
|
|||
// Highlight changes
|
||||
if(_changedList[pos])
|
||||
{
|
||||
s.fillRect(x - 3, y - 1, _colWidth-1, _rowHeight-1, onTop ? kDbgChangedColor : _bgcolorlo);
|
||||
s.fillRect(x - 3, y - 1, _colWidth-1, _rowHeight-1,
|
||||
onTop ? uInt32(kDbgChangedColor) : _bgcolorlo);
|
||||
s.drawString(_font, buffer, x, y, _colWidth, onTop ? kDbgChangedTextColor : kColor);
|
||||
}
|
||||
else
|
||||
s.drawString(_font, buffer, x, y, _colWidth, onTop ? textColor : kColor);
|
||||
s.drawString(_font, buffer, x, y, _colWidth,
|
||||
onTop ? textColor : uInt32(kColor));
|
||||
}
|
||||
else
|
||||
{
|
||||
|
|
|
@ -137,7 +137,8 @@ void CheckListWidget::drawWidget(bool hilite)
|
|||
TextAlign::Left, -_editScrollOffset, false);
|
||||
}
|
||||
else
|
||||
s.drawString(_font, _list[pos], _x + r.left, y, r.width(), onTop ? textColor : kColor);
|
||||
s.drawString(_font, _list[pos], _x + r.left, y, r.width(),
|
||||
onTop ? textColor : uInt32(kColor));
|
||||
}
|
||||
|
||||
// Only draw the caret while editing, and if it's in the current viewport
|
||||
|
|
|
@ -96,7 +96,7 @@ void EditTextWidget::drawWidget(bool hilite)
|
|||
s.drawString(_font, editString(), _x + 2, _y + 2, getEditRect().width(),
|
||||
_changed && onTop
|
||||
? uInt32(kDbgChangedTextColor)
|
||||
: onTop ? _textcolor : kColor,
|
||||
: onTop ? _textcolor : uInt32(kColor),
|
||||
TextAlign::Left, -_editScrollOffset, false);
|
||||
|
||||
// Draw the caret
|
||||
|
|
|
@ -645,8 +645,9 @@ void CheckboxWidget::drawWidget(bool hilite)
|
|||
if(_drawBox)
|
||||
s.frameRect(_x, _y + _boxY, 14, 14, onTop && hilite && isEnabled() && isEditable() ? kWidColorHi : kColor);
|
||||
// Do we draw a square or cross?
|
||||
s.fillRect(_x + 1, _y + _boxY + 1, 12, 12, _changed ? onTop ? uInt32(kDbgChangedColor) : kDlgColor
|
||||
: isEnabled() ? onTop ? _bgcolor : kDlgColor : uInt32(kColor));
|
||||
s.fillRect(_x + 1, _y + _boxY + 1, 12, 12,
|
||||
_changed ? onTop ? uInt32(kDbgChangedColor) : uInt32(kDlgColor) :
|
||||
isEnabled() ? onTop ? _bgcolor : uInt32(kDlgColor) : uInt32(kColor));
|
||||
if(_state)
|
||||
s.drawBitmap(_img, _x + 2, _y + _boxY + 2, onTop && isEnabled() ? hilite && isEditable() ? kWidColorHi : kCheckColor
|
||||
: kColor, 10);
|
||||
|
|
Loading…
Reference in New Issue