From e6dae567f938a29fd6f5929e52e87a7c6abd1a94 Mon Sep 17 00:00:00 2001 From: Stephen Anthony Date: Thu, 15 Oct 2020 11:29:58 -0230 Subject: [PATCH] Fix some warnings from clang. --- src/debugger/gui/RamWidget.hxx | 1 - src/gui/CheckListWidget.cxx | 6 +++--- src/gui/StringListWidget.cxx | 6 +++--- 3 files changed, 6 insertions(+), 7 deletions(-) diff --git a/src/debugger/gui/RamWidget.hxx b/src/debugger/gui/RamWidget.hxx index f7391c8e4..fbc7747e6 100644 --- a/src/debugger/gui/RamWidget.hxx +++ b/src/debugger/gui/RamWidget.hxx @@ -100,7 +100,6 @@ class RamWidget : public Widget, public CommandSender DataGridWidget* myRamGrid{nullptr}; DataGridWidget* myHexValue{nullptr}; DataGridWidget* myDecValue{nullptr}; - DataGridWidget* mySignValue{nullptr}; DataGridWidget* myBinValue{nullptr}; EditTextWidget* myLabel{nullptr}; diff --git a/src/gui/CheckListWidget.cxx b/src/gui/CheckListWidget.cxx index f2cba25b6..08852a4f8 100644 --- a/src/gui/CheckListWidget.cxx +++ b/src/gui/CheckListWidget.cxx @@ -142,9 +142,9 @@ void CheckListWidget::drawWidget(bool hilite) // Only draw the caret while editing, and if it's in the current viewport if(_editMode && - (!(_useScrollbar) || - (_selectedItem >= _scrollBar->_currentPos) && - (_selectedItem < _scrollBar->_currentPos + _rows))) + (!_useScrollbar || + ((_selectedItem >= _scrollBar->_currentPos) && + (_selectedItem < _scrollBar->_currentPos + _rows)))) drawCaret(); } diff --git a/src/gui/StringListWidget.cxx b/src/gui/StringListWidget.cxx index ba112ff46..f388aaeff 100644 --- a/src/gui/StringListWidget.cxx +++ b/src/gui/StringListWidget.cxx @@ -109,9 +109,9 @@ void StringListWidget::drawWidget(bool hilite) // Only draw the caret while editing, and if it's in the current viewport if(_editMode && - (!(_useScrollbar) || - (_selectedItem >= _scrollBar->_currentPos) && - (_selectedItem < _scrollBar->_currentPos + _rows))) + (!_useScrollbar || + ((_selectedItem >= _scrollBar->_currentPos) && + (_selectedItem < _scrollBar->_currentPos + _rows)))) drawCaret(); }