From 2d9c9a500321ca8a64214f56754651623f80b36d Mon Sep 17 00:00:00 2001 From: thrust26 Date: Sat, 28 Nov 2020 16:54:23 +0100 Subject: [PATCH] made DelayQueueWidget use setDirty removed superfluous code from TiaWidget --- src/debugger/gui/DelayQueueWidget.cxx | 12 ++++++++++-- src/debugger/gui/TiaWidget.cxx | 4 ---- 2 files changed, 10 insertions(+), 6 deletions(-) diff --git a/src/debugger/gui/DelayQueueWidget.cxx b/src/debugger/gui/DelayQueueWidget.cxx index cca5644c6..d0ad50351 100644 --- a/src/debugger/gui/DelayQueueWidget.cxx +++ b/src/debugger/gui/DelayQueueWidget.cxx @@ -50,7 +50,11 @@ void DelayQueueWidget::loadConfig() { using Common::Base; for (auto&& line : myLines) { if (!delayQueueIterator->isValid()) { - line = ""; + if(line != "") + { + setDirty(); + line = ""; + } continue; } @@ -81,7 +85,11 @@ void DelayQueueWidget::loadConfig() { break; } - line = ss.str(); + if(line != ss.str()) + { + setDirty(); + line = ss.str(); + } delayQueueIterator->next(); } } diff --git a/src/debugger/gui/TiaWidget.cxx b/src/debugger/gui/TiaWidget.cxx index c330bf386..f6bc43e6e 100644 --- a/src/debugger/gui/TiaWidget.cxx +++ b/src/debugger/gui/TiaWidget.cxx @@ -919,14 +919,10 @@ void TiaWidget::handleCommand(CommandSender* sender, int cmd, int data, int id) case kRefP0ID: tia.refP0(myRefP0->getState() ? 1 : 0); - myGRP0->setIntState(myGRP0->getIntState(), !myRefP0->getState()); - myGRP0Old->setIntState(myGRP0Old->getIntState(), !myRefP0->getState()); break; case kRefP1ID: tia.refP1(myRefP1->getState() ? 1 : 0); - myGRP1->setIntState(myGRP1->getIntState(), !myRefP1->getState()); - myGRP1Old->setIntState(myGRP1Old->getIntState(), !myRefP1->getState()); break; case kDelP0ID: