Debian Codegraph @

memorydumppane.cpp

raw symbols SCIP
1 // File: memorydumppane.cppcxx . . $ `<file>/memorydumppane.cpp`/
2 /*
3 Pep8-1 is a virtual machine for writing machine language and assembly
4 language programs.
5
6 Copyright (C) 2009 J. Stanley Warford, Pepperdine University
7
8 This program is free software: you can redistribute it and/or modify
9 it under the terms of the GNU General Public License as published by
10 the Free Software Foundation, either version 3 of the License, or
11 (at your option) any later version.
12
13 This program is distributed in the hope that it will be useful,
14 but WITHOUT ANY WARRANTY; without even the implied warranty of
15 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
16 GNU General Public License for more details.
17
18 You should have received a copy of the GNU General Public License
19 along with this program. If not, see <http://www.gnu.org/licenses/>.
20 */
21 #include <QFontDialog>
22 #include <QTextCharFormat>
23 #include <QAbstractTextDocumentLayout>
24 #include "memorydumppane.h"cxx . . $ `<file>/memorydumppane.h`/
25 #include "ui_memorydumppane.h"cxx . . $ `<file>/ui_memorydumppane.h`/
26 #include "sim.h"cxx . . $ `<file>/sim.h`/
27 #include "pep.h"cxx . . $ `<file>/pep.h`/
28 #include "enu.h"cxx . . $ `<file>/enu.h`/
29
30 #include <QDebug>
31
32 MemoryDumpPanecxx . . $ MemoryDumpPane#::MemoryDumpPanecxx . . $ MemoryDumpPane#MemoryDumpPane(108f35f7aa7f3cf9).(QWidgetcxx . . $ QWidget# *parent) :
33 QWidgetcxx . . $ QWidget#QWidget(872e7b0c281abd8d).(parent),
34 uicxx . . $ MemoryDumpPane#ui.(new Uicxx . . $ Ui/::MemoryDumpPanecxx . . $ Ui/MemoryDumpPane#)
35 {
36 uicxx . . $ MemoryDumpPane#ui.->setupUicxx . . $ Ui_MemoryDumpPane#setupUi(108f35f7aa7f3cf9).(this);
37
38 if (Pepcxx . . $ Pep#::getSystemcxx . . $ Pep#getSystem(4365c3963150523e).() !=cxx . . $ QString#`operator!=`(7d4bdb1abc417636). "Mac") {
39 uicxx . . $ MemoryDumpPane#ui.->labelcxx . . $ Ui_MemoryDumpPane#label.->setFontcxx . . $ QWidget#setFont(d0a4bd0c8524b912).(QFontcxx . . $ QFont#QFont(7ae16150a604556).(Pepcxx . . $ Pep#::labelFontcxx . . $ Pep#labelFont., Pepcxx . . $ Pep#::labelFontSizecxx . . $ Pep#labelFontSize.));
40 uicxx . . $ MemoryDumpPane#ui.->textEditcxx . . $ Ui_MemoryDumpPane#textEdit.->setFontcxx . . $ QWidget#setFont(d0a4bd0c8524b912).(QFontcxx . . $ QFont#QFont(7ae16150a604556).(Pepcxx . . $ Pep#::codeFontcxx . . $ Pep#codeFont., Pepcxx . . $ Pep#::codeFontSizecxx . . $ Pep#codeFontSize.));
41 }
42
43 connectcxx . . $ QObject#connect(158df1d9a01a3410).(uicxx . . $ MemoryDumpPane#ui.->pcPushButtoncxx . . $ Ui_MemoryDumpPane#pcPushButton., SIGNALcxx . . $ `<external>/1208926524888476972/qobjectdefs.h:271:10`!(clicked()), this, SLOTcxx . . $ `<external>/1208926524888476972/qobjectdefs.h:270:10`!(scrollToPC()));
44 connectcxx . . $ QObject#connect(158df1d9a01a3410).(uicxx . . $ MemoryDumpPane#ui.->spPushButtoncxx . . $ Ui_MemoryDumpPane#spPushButton., SIGNALcxx . . $ `<external>/1208926524888476972/qobjectdefs.h:271:10`!(clicked()), this, SLOTcxx . . $ `<external>/1208926524888476972/qobjectdefs.h:270:10`!(scrollToSP()));
45 connectcxx . . $ QObject#connect(158df1d9a01a3410).(uicxx . . $ MemoryDumpPane#ui.->scrollToLineEditcxx . . $ Ui_MemoryDumpPane#scrollToLineEdit., SIGNALcxx . . $ `<external>/1208926524888476972/qobjectdefs.h:271:10`!(textChanged(QString)), this, SLOTcxx . . $ `<external>/1208926524888476972/qobjectdefs.h:270:10`!(scrollToAddress(QString)));
46 }
47
48 MemoryDumpPanecxx . . $ MemoryDumpPane#::~cxx . . $ MemoryDumpPane#`~MemoryDumpPane`(ced63f7c635d850d).MemoryDumpPanecxx . . $ MemoryDumpPane#()
49 {
50 delete uicxx . . $ MemoryDumpPane#ui.;
51 }
52
53 void MemoryDumpPanecxx . . $ MemoryDumpPane#::refreshMemorycxx . . $ MemoryDumpPane#refreshMemory(49f6e7a06ebc5aa8).()
54 {
55 QStringListcxx . . $ QStringList# memoryDumpcxx . . $ QStringList#QStringList(ced63f7c635d850d).;
56 QStringcxx . . $ QString# memoryDumpLinecxx . . $ QString#QString(ced63f7c635d850d).;
57 QCharcxx . . $ QChar# chcxx . . $ QChar#QChar(ced63f7c635d850d).;
58 for (int i = 0; i < 65536; i += 8) {
59 memoryDumpLine =cxx . . $ QString#`operator=`(d02845eef0c33901). "";
60 memoryDumpLine.appendcxx . . $ QString#append(6a89d0b7f4d2681c).(QStringcxx . . $ QString#QString(85c52e162fed56f9).("%1 | ").argcxx . . $ QString#arg(64ab2ed17cc11715).(i, 4, 16, QLatin1Charcxx . . $ QChar#QChar(a50889c09eec06d9).('0')).toUppercxx . . $ QString#toUpper(30b3b70527b1c61a).());
61 for (int j = 0; j < 8; j++) {
62 memoryDumpLine.appendcxx . . $ QString#append(6a89d0b7f4d2681c).(QStringcxx . . $ QString#QString(85c52e162fed56f9).("%1 ").argcxx . . $ QString#arg(64ab2ed17cc11715).(Simcxx . . $ Sim#::Memcxx . . $ Sim#Mem.[cxx . . $ QVector#`operator[]`(7a0ef1c7079e8533).i + j], 2, 16, QLatin1Charcxx . . $ QChar#QChar(a50889c09eec06d9).('0')).toUppercxx . . $ QString#toUpper(30b3b70527b1c61a).());
63 }
64 memoryDumpLine.appendcxx . . $ QString#append(d02845eef0c33901).("|");
65 for (int j = 0; j < 8; j++) {
66 ch =cxx . . $ QChar#`operator=`(81d7e7f12920c16). QCharcxx . . $ QChar#(Simcxx . . $ Sim#::Memcxx . . $ Sim#Mem.[cxx . . $ QVector#`operator[]`(7a0ef1c7079e8533).i + j]);
67 if (ch.isPrintcxx . . $ QChar#isPrint(3482b152b9333168).()) {
68 memoryDumpLine.appendcxx . . $ QString#append(3a2ffbdf8ecc25e2).(ch);
69 } else {
70 memoryDumpLine.appendcxx . . $ QString#append(d02845eef0c33901).(".");
71 }
72 }
73 memoryDump.appendcxx . . $ QList#append(77d9f17553126ecb).(memoryDumpLine);
74 }
75 uicxx . . $ MemoryDumpPane#ui.->textEditcxx . . $ Ui_MemoryDumpPane#textEdit.->setTextcxx . . $ QTextEdit#setText(3520e46b33348bf6).(memoryDump.joincxx . . $ QListSpecialMethods#join(5555d9024dcf93fb).("\n"cxx . . $ QString#QString(85c52e162fed56f9).));
76 }
77
78 void MemoryDumpPanecxx . . $ MemoryDumpPane#::refreshMemoryLinescxx . . $ MemoryDumpPane#refreshMemoryLines(3e454b8ccf442868).(int firstByte, int lastByte)
79 {
80 int vertScrollBarPosition = uicxx . . $ MemoryDumpPane#ui.->textEditcxx . . $ Ui_MemoryDumpPane#textEdit.->verticalScrollBarcxx . . $ QAbstractScrollArea#verticalScrollBar(49d9510c6adf8c19).()->valuecxx . . $ QAbstractSlider#value(455f465bc33b4cdf).();
81 int horizScrollBarPosition = uicxx . . $ MemoryDumpPane#ui.->textEditcxx . . $ Ui_MemoryDumpPane#textEdit.->horizontalScrollBarcxx . . $ QAbstractScrollArea#horizontalScrollBar(49d9510c6adf8c19).()->valuecxx . . $ QAbstractSlider#value(455f465bc33b4cdf).();
82
83 int firstLine = firstByte / 8;
84 int lastLine = lastByte / 8;
85
86 QTextCursorcxx . . $ QTextCursor# cursorcxx . . $ QTextCursor#QTextCursor(68d7deb16251beb9).(uicxx . . $ MemoryDumpPane#ui.->textEditcxx . . $ Ui_MemoryDumpPane#textEdit.->documentcxx . . $ QTextEdit#document(f21741221844491e).());
87 cursor.setPositioncxx . . $ QTextCursor#setPosition(f2a23d9eedd3abdd).(0);
88 for (int i = 0; i < firstLine; i++) {
89 cursor.movePositioncxx . . $ QTextCursor#movePosition(e5e992d8a5d1c17e).(QTextCursorcxx . . $ QTextCursor#::NextBlockcxx . . $ QTextCursor#NextBlock.);
90 }
91
92 QStringcxx . . $ QString# memoryDumpLinecxx . . $ QString#QString(ced63f7c635d850d).;
93 QCharcxx . . $ QChar# chcxx . . $ QChar#QChar(ced63f7c635d850d).;
94 int byteNum;
95 for (int i = firstLine; i <= lastLine; i++) {
96 memoryDumpLine =cxx . . $ QString#`operator=`(d02845eef0c33901). "";
97 byteNum = i * 8;
98 memoryDumpLine.appendcxx . . $ QString#append(6a89d0b7f4d2681c).(QStringcxx . . $ QString#QString(85c52e162fed56f9).("%1 | ").argcxx . . $ QString#arg(64ab2ed17cc11715).(byteNum, 4, 16, QLatin1Charcxx . . $ QChar#QChar(a50889c09eec06d9).('0')).toUppercxx . . $ QString#toUpper(30b3b70527b1c61a).());
99 for (int j = 0; j < 8; j++) {
100 memoryDumpLine.appendcxx . . $ QString#append(6a89d0b7f4d2681c).(QStringcxx . . $ QString#QString(85c52e162fed56f9).("%1 ").argcxx . . $ QString#arg(64ab2ed17cc11715).(Simcxx . . $ Sim#::Memcxx . . $ Sim#Mem.[cxx . . $ QVector#`operator[]`(7a0ef1c7079e8533).byteNum++], 2, 16, QLatin1Charcxx . . $ QChar#QChar(a50889c09eec06d9).('0')).toUppercxx . . $ QString#toUpper(30b3b70527b1c61a).());
101 }
102 memoryDumpLine.appendcxx . . $ QString#append(d02845eef0c33901).("|");
103 byteNum = i * 8;
104 for (int j = 0; j < 8; j++) {
105 ch =cxx . . $ QChar#`operator=`(81d7e7f12920c16). QCharcxx . . $ QChar#(Simcxx . . $ Sim#::Memcxx . . $ Sim#Mem.[cxx . . $ QVector#`operator[]`(7a0ef1c7079e8533).byteNum++]);
106 if (ch.isPrintcxx . . $ QChar#isPrint(3482b152b9333168).()) {
107 memoryDumpLine.appendcxx . . $ QString#append(3a2ffbdf8ecc25e2).(ch);
108 } else {
109 memoryDumpLine.appendcxx . . $ QString#append(d02845eef0c33901).(".");
110 }
111 }
112 cursor.movePositioncxx . . $ QTextCursor#movePosition(e5e992d8a5d1c17e).(QTextCursorcxx . . $ QTextCursor#::EndOfLinecxx . . $ QTextCursor#EndOfLine., QTextCursorcxx . . $ QTextCursor#::KeepAnchorcxx . . $ QTextCursor#KeepAnchor.);
113 uicxx . . $ MemoryDumpPane#ui.->textEditcxx . . $ Ui_MemoryDumpPane#textEdit.->setTextCursorcxx . . $ QTextEdit#setTextCursor(a408cee6726ac3d5).(cursor);
114 uicxx . . $ MemoryDumpPane#ui.->textEditcxx . . $ Ui_MemoryDumpPane#textEdit.->insertPlainTextcxx . . $ QTextEdit#insertPlainText(3520e46b33348bf6).(memoryDumpLine);
115 cursor.movePositioncxx . . $ QTextCursor#movePosition(e5e992d8a5d1c17e).(QTextCursorcxx . . $ QTextCursor#::NextBlockcxx . . $ QTextCursor#NextBlock.);
116 }
117
118 uicxx . . $ MemoryDumpPane#ui.->textEditcxx . . $ Ui_MemoryDumpPane#textEdit.->verticalScrollBarcxx . . $ QAbstractScrollArea#verticalScrollBar(49d9510c6adf8c19).()->setValuecxx . . $ QAbstractSlider#setValue(d4f767463ce0a6b3).(vertScrollBarPosition);
119 uicxx . . $ MemoryDumpPane#ui.->textEditcxx . . $ Ui_MemoryDumpPane#textEdit.->horizontalScrollBarcxx . . $ QAbstractScrollArea#horizontalScrollBar(49d9510c6adf8c19).()->setValuecxx . . $ QAbstractSlider#setValue(d4f767463ce0a6b3).(horizScrollBarPosition);
120 }
121
122 void MemoryDumpPanecxx . . $ MemoryDumpPane#::highlightMemorycxx . . $ MemoryDumpPane#highlightMemory(b45ddcbc8423892c).(bool b)
123 {
124 while (!highlightedDatacxx . . $ MemoryDumpPane#highlightedData..isEmptycxx . . $ QList#isEmpty(3482b152b9333168).()) {
125 highlightBytecxx . . $ MemoryDumpPane#highlightByte(6f91d3f73a5b9054).(highlightedDatacxx . . $ MemoryDumpPane#highlightedData..takeFirstcxx . . $ QList#takeFirst(5f357b03ed472e5e).(), Qtcxx . . $ QColor#QColor(408ec4d5924bfb00).::blackcxx . . $ Qt/black., Qtcxx . . $ QColor#QColor(408ec4d5924bfb00).::whitecxx . . $ Qt/white.);
126 }
127
128 if (b) {
129 highlightBytecxx . . $ MemoryDumpPane#highlightByte(6f91d3f73a5b9054).(Simcxx . . $ Sim#::stackPointercxx . . $ Sim#stackPointer., Qtcxx . . $ QColor#QColor(408ec4d5924bfb00).::whitecxx . . $ Qt/white., Qtcxx . . $ QColor#QColor(408ec4d5924bfb00).::darkMagentacxx . . $ Qt/darkMagenta.);
130 highlightedDatacxx . . $ MemoryDumpPane#highlightedData..appendcxx . . $ QList#append(77d9f17553126ecb).(Simcxx . . $ Sim#::stackPointercxx . . $ Sim#stackPointer.);
131
132 if (!Pepcxx . . $ Pep#::isUnaryMapcxx . . $ Pep#isUnaryMap..valuecxx . . $ QMap#value(866b0a4e5fb46e14).(Pepcxx . . $ Pep#::decodeMnemoniccxx . . $ Pep#decodeMnemonic..valuecxx . . $ QVector#value(b4be2ec6940d8d62).(Simcxx . . $ Sim#::readBytecxx . . $ Sim#readByte(7864480464b09eea).(Simcxx . . $ Sim#::programCountercxx . . $ Sim#programCounter.)))) {
133 QTextCursorcxx . . $ QTextCursor# cursorcxx . . $ QTextCursor#QTextCursor(68d7deb16251beb9).(uicxx . . $ MemoryDumpPane#ui.->textEditcxx . . $ Ui_MemoryDumpPane#textEdit.->documentcxx . . $ QTextEdit#document(f21741221844491e).());
134 QTextCharFormatcxx . . $ QTextCharFormat# formatcxx . . $ QTextCharFormat#QTextCharFormat(49f6e7a06ebc5aa8).;
135 format.setBackgroundcxx . . $ QTextFormat#setBackground(ffc9f5d0bda78261).(Qtcxx . . $ QBrush#QBrush(1975e3c608654284).::bluecxx . . $ Qt/blue.);
136 format.setForegroundcxx . . $ QTextFormat#setForeground(ffc9f5d0bda78261).(Qtcxx . . $ QBrush#QBrush(1975e3c608654284).::whitecxx . . $ Qt/white.);
137 cursor.setPositioncxx . . $ QTextCursor#setPosition(f2a23d9eedd3abdd).(0);
138 for (int i = 0; i < Simcxx . . $ Sim#::programCountercxx . . $ Sim#programCounter. / 8; i++) {
139 cursor.movePositioncxx . . $ QTextCursor#movePosition(e5e992d8a5d1c17e).(QTextCursorcxx . . $ QTextCursor#::NextBlockcxx . . $ QTextCursor#NextBlock.);
140 }
141 for (int i = 0; i < 7 + 3 * (Simcxx . . $ Sim#::programCountercxx . . $ Sim#programCounter. % 8); i++) {
142 cursor.movePositioncxx . . $ QTextCursor#movePosition(e5e992d8a5d1c17e).(QTextCursorcxx . . $ QTextCursor#::NextCharactercxx . . $ QTextCursor#NextCharacter.);
143 }
144 cursor.movePositioncxx . . $ QTextCursor#movePosition(e5e992d8a5d1c17e).(QTextCursorcxx . . $ QTextCursor#::NextCharactercxx . . $ QTextCursor#NextCharacter., QTextCursorcxx . . $ QTextCursor#::KeepAnchorcxx . . $ QTextCursor#KeepAnchor., 2);
145 cursor.mergeCharFormatcxx . . $ QTextCursor#mergeCharFormat(dd8d5568386b23bd).(format);
146 highlightedDatacxx . . $ MemoryDumpPane#highlightedData..appendcxx . . $ QList#append(77d9f17553126ecb).(Simcxx . . $ Sim#::programCountercxx . . $ Sim#programCounter.);
147 if (Simcxx . . $ Sim#::programCountercxx . . $ Sim#programCounter. / 8 == (Simcxx . . $ Sim#::programCountercxx . . $ Sim#programCounter. + 1) / 8) {
148 cursor.clearSelectioncxx . . $ QTextCursor#clearSelection(49f6e7a06ebc5aa8).();
149 cursor.movePositioncxx . . $ QTextCursor#movePosition(e5e992d8a5d1c17e).(QTextCursorcxx . . $ QTextCursor#::NextCharactercxx . . $ QTextCursor#NextCharacter.);
150 cursor.movePositioncxx . . $ QTextCursor#movePosition(e5e992d8a5d1c17e).(QTextCursorcxx . . $ QTextCursor#::NextCharactercxx . . $ QTextCursor#NextCharacter., QTextCursorcxx . . $ QTextCursor#::KeepAnchorcxx . . $ QTextCursor#KeepAnchor., 2);
151 cursor.mergeCharFormatcxx . . $ QTextCursor#mergeCharFormat(dd8d5568386b23bd).(format);
152 }
153 else {
154 cursor.clearSelectioncxx . . $ QTextCursor#clearSelection(49f6e7a06ebc5aa8).();
155 cursor.movePositioncxx . . $ QTextCursor#movePosition(e5e992d8a5d1c17e).(QTextCursorcxx . . $ QTextCursor#::NextBlockcxx . . $ QTextCursor#NextBlock.);
156 cursor.movePositioncxx . . $ QTextCursor#movePosition(e5e992d8a5d1c17e).(QTextCursorcxx . . $ QTextCursor#::NextCharactercxx . . $ QTextCursor#NextCharacter., QTextCursorcxx . . $ QTextCursor#::MoveAnchorcxx . . $ QTextCursor#MoveAnchor., 7);
157 cursor.movePositioncxx . . $ QTextCursor#movePosition(e5e992d8a5d1c17e).(QTextCursorcxx . . $ QTextCursor#::NextCharactercxx . . $ QTextCursor#NextCharacter., QTextCursorcxx . . $ QTextCursor#::KeepAnchorcxx . . $ QTextCursor#KeepAnchor., 2);
158 cursor.mergeCharFormatcxx . . $ QTextCursor#mergeCharFormat(dd8d5568386b23bd).(format);
159 }
160 highlightedDatacxx . . $ MemoryDumpPane#highlightedData..appendcxx . . $ QList#append(77d9f17553126ecb).(Simcxx . . $ Sim#::addcxx . . $ Sim#add(9b79fb6aee4c0440).(Simcxx . . $ Sim#::programCountercxx . . $ Sim#programCounter., 1));
161 if ((Simcxx . . $ Sim#::programCountercxx . . $ Sim#programCounter. + 1) / 8 == (Simcxx . . $ Sim#::programCountercxx . . $ Sim#programCounter. + 2) / 8) {
162 cursor.clearSelectioncxx . . $ QTextCursor#clearSelection(49f6e7a06ebc5aa8).();
163 cursor.movePositioncxx . . $ QTextCursor#movePosition(e5e992d8a5d1c17e).(QTextCursorcxx . . $ QTextCursor#::NextCharactercxx . . $ QTextCursor#NextCharacter.);
164 cursor.movePositioncxx . . $ QTextCursor#movePosition(e5e992d8a5d1c17e).(QTextCursorcxx . . $ QTextCursor#::NextCharactercxx . . $ QTextCursor#NextCharacter., QTextCursorcxx . . $ QTextCursor#::KeepAnchorcxx . . $ QTextCursor#KeepAnchor., 2);
165 cursor.mergeCharFormatcxx . . $ QTextCursor#mergeCharFormat(dd8d5568386b23bd).(format);
166 }
167 else {
168 cursor.clearSelectioncxx . . $ QTextCursor#clearSelection(49f6e7a06ebc5aa8).();
169 cursor.movePositioncxx . . $ QTextCursor#movePosition(e5e992d8a5d1c17e).(QTextCursorcxx . . $ QTextCursor#::NextBlockcxx . . $ QTextCursor#NextBlock.);
170 cursor.movePositioncxx . . $ QTextCursor#movePosition(e5e992d8a5d1c17e).(QTextCursorcxx . . $ QTextCursor#::NextCharactercxx . . $ QTextCursor#NextCharacter., QTextCursorcxx . . $ QTextCursor#::MoveAnchorcxx . . $ QTextCursor#MoveAnchor., 7);
171 cursor.movePositioncxx . . $ QTextCursor#movePosition(e5e992d8a5d1c17e).(QTextCursorcxx . . $ QTextCursor#::NextCharactercxx . . $ QTextCursor#NextCharacter., QTextCursorcxx . . $ QTextCursor#::KeepAnchorcxx . . $ QTextCursor#KeepAnchor., 2);
172 cursor.mergeCharFormatcxx . . $ QTextCursor#mergeCharFormat(dd8d5568386b23bd).(format);
173 }
174 highlightedDatacxx . . $ MemoryDumpPane#highlightedData..appendcxx . . $ QList#append(77d9f17553126ecb).(Simcxx . . $ Sim#::addcxx . . $ Sim#add(9b79fb6aee4c0440).(Simcxx . . $ Sim#::programCountercxx . . $ Sim#programCounter., 2));
175 }
176 else { // unary.
177 highlightBytecxx . . $ MemoryDumpPane#highlightByte(6f91d3f73a5b9054).(Simcxx . . $ Sim#::programCountercxx . . $ Sim#programCounter., Qtcxx . . $ QColor#QColor(408ec4d5924bfb00).::whitecxx . . $ Qt/white., Qtcxx . . $ QColor#QColor(408ec4d5924bfb00).::bluecxx . . $ Qt/blue.);
178 highlightedDatacxx . . $ MemoryDumpPane#highlightedData..appendcxx . . $ QList#append(77d9f17553126ecb).(Simcxx . . $ Sim#::programCountercxx . . $ Sim#programCounter.);
179 }
180
181 bytesWrittenLastStepcxx . . $ MemoryDumpPane#bytesWrittenLastStep. =cxx . . $ QList#`operator=`(fb6690361a2f6b44). bytesWrittenLastStepcxx . . $ MemoryDumpPane#bytesWrittenLastStep..toSetcxx . . $ QList#toSet(c8a5c51d39a34950).().toListcxx . . $ QSet#toList(bf6c511543d55010).();
182 qSortcxx . . $ qSort(8e935d9c2e576e3a).(bytesWrittenLastStepcxx . . $ MemoryDumpPane#bytesWrittenLastStep.);
183 while (!bytesWrittenLastStepcxx . . $ MemoryDumpPane#bytesWrittenLastStep..isEmptycxx . . $ QList#isEmpty(3482b152b9333168).()) {
184 // This is to prevent bytes modified by the OS from being highlighted when we are not tracing traps:
185 if (bytesWrittenLastStepcxx . . $ MemoryDumpPane#bytesWrittenLastStep..atcxx . . $ QList#at(e2681f9bb6b2f357).(0) < Simcxx . . $ Sim#::readWordcxx . . $ Sim#readWord(7864480464b09eea).(Pepcxx . . $ Pep#::dotBurnArgumentcxx . . $ Pep#dotBurnArgument. - 0x7) || Simcxx . . $ Sim#::trappedcxx . . $ Sim#trapped.) {
186 highlightBytecxx . . $ MemoryDumpPane#highlightByte(6f91d3f73a5b9054).(bytesWrittenLastStepcxx . . $ MemoryDumpPane#bytesWrittenLastStep..atcxx . . $ QList#at(e2681f9bb6b2f357).(0), Qtcxx . . $ QColor#QColor(408ec4d5924bfb00).::whitecxx . . $ Qt/white., Qtcxx . . $ QColor#QColor(408ec4d5924bfb00).::redcxx . . $ Qt/red.);
187 highlightedDatacxx . . $ MemoryDumpPane#highlightedData..appendcxx . . $ QList#append(77d9f17553126ecb).(bytesWrittenLastStepcxx . . $ MemoryDumpPane#bytesWrittenLastStep..takeFirstcxx . . $ QList#takeFirst(5f357b03ed472e5e).());
188 }
189 else {
190 return;
191 }
192 }
193 }
194 }
195
196 void MemoryDumpPanecxx . . $ MemoryDumpPane#::cacheModifiedBytescxx . . $ MemoryDumpPane#cacheModifiedBytes(49f6e7a06ebc5aa8).()
197 {
198 modifiedBytescxx . . $ MemoryDumpPane#modifiedBytes..unitecxx . . $ QSet#unite(ccebfa87892ac54d).(Simcxx . . $ Sim#::modifiedBytescxx . . $ Sim#modifiedBytes.);
199 if (Simcxx . . $ Sim#::tracingTrapscxx . . $ Sim#tracingTraps.) {
200 bytesWrittenLastStepcxx . . $ MemoryDumpPane#bytesWrittenLastStep..clearcxx . . $ QList#clear(49f6e7a06ebc5aa8).();
201 bytesWrittenLastStepcxx . . $ MemoryDumpPane#bytesWrittenLastStep. =cxx . . $ QList#`operator=`(fb6690361a2f6b44). Simcxx . . $ Sim#::modifiedBytescxx . . $ Sim#modifiedBytes..toListcxx . . $ QSet#toList(bf6c511543d55010).();
202 }
203 else if (Simcxx . . $ Sim#::trappedcxx . . $ Sim#trapped.) {
204 delayLastStepClearcxx . . $ MemoryDumpPane#delayLastStepClear. = true;
205 bytesWrittenLastStepcxx . . $ MemoryDumpPane#bytesWrittenLastStep..appendcxx . . $ QList#append(3d2301cfd89f773a).(Simcxx . . $ Sim#::modifiedBytescxx . . $ Sim#modifiedBytes..toListcxx . . $ QSet#toList(bf6c511543d55010).());
206 }
207 else if (delayLastStepClearcxx . . $ MemoryDumpPane#delayLastStepClear.) {
208 delayLastStepClearcxx . . $ MemoryDumpPane#delayLastStepClear. = false;
209 }
210 else {
211 bytesWrittenLastStepcxx . . $ MemoryDumpPane#bytesWrittenLastStep..clearcxx . . $ QList#clear(49f6e7a06ebc5aa8).();
212 bytesWrittenLastStepcxx . . $ MemoryDumpPane#bytesWrittenLastStep. =cxx . . $ QList#`operator=`(fb6690361a2f6b44). Simcxx . . $ Sim#::modifiedBytescxx . . $ Sim#modifiedBytes..toListcxx . . $ QSet#toList(bf6c511543d55010).();
213 }
214 }
215
216 void MemoryDumpPanecxx . . $ MemoryDumpPane#::updateMemorycxx . . $ MemoryDumpPane#updateMemory(49f6e7a06ebc5aa8).()
217 {
218 int vertScrollBarPosition = uicxx . . $ MemoryDumpPane#ui.->textEditcxx . . $ Ui_MemoryDumpPane#textEdit.->verticalScrollBarcxx . . $ QAbstractScrollArea#verticalScrollBar(49d9510c6adf8c19).()->valuecxx . . $ QAbstractSlider#value(455f465bc33b4cdf).();
219 int horizScrollBarPosition = uicxx . . $ MemoryDumpPane#ui.->textEditcxx . . $ Ui_MemoryDumpPane#textEdit.->horizontalScrollBarcxx . . $ QAbstractScrollArea#horizontalScrollBar(49d9510c6adf8c19).()->valuecxx . . $ QAbstractSlider#value(455f465bc33b4cdf).();
220
221 QListcxx . . $ QList#<int> listcxx . . $ QList#QList(ced63f7c635d850d).;
222 QSetcxx . . $ QSet#<int> linesToBeUpdatedcxx . . $ QSet#QSet(ced63f7c635d850d).;
223 QStringcxx . . $ QString# memoryDumpLinecxx . . $ QString#QString(ced63f7c635d850d).;
224 QCharcxx . . $ QChar# chcxx . . $ QChar#QChar(ced63f7c635d850d).;
225 int byteNum;
226 int lineNum;
227
228 modifiedBytescxx . . $ MemoryDumpPane#modifiedBytes..unitecxx . . $ QSet#unite(ccebfa87892ac54d).(Simcxx . . $ Sim#::modifiedBytescxx . . $ Sim#modifiedBytes.);
229 list =cxx . . $ QList#`operator=`(fb6690361a2f6b44). modifiedBytescxx . . $ MemoryDumpPane#modifiedBytes..toListcxx . . $ QSet#toList(bf6c511543d55010).();
230 while(!list.isEmptycxx . . $ QList#isEmpty(3482b152b9333168).()) {
231 linesToBeUpdated.insertcxx . . $ QSet#insert(b1720532d625d779).(list.takeFirstcxx . . $ QList#takeFirst(5f357b03ed472e5e).() / 8);
232 }
233 list =cxx . . $ QList#`operator=`(fb6690361a2f6b44). linesToBeUpdated.toListcxx . . $ QSet#toList(bf6c511543d55010).();
234 qSortcxx . . $ qSort(249673c20e2b8d5).(list.begincxx . . $ QList#begin(ca2520f641887418).(), list.endcxx . . $ QList#end(ca2520f641887418).());
235 QTextCursorcxx . . $ QTextCursor# cursorcxx . . $ QTextCursor#QTextCursor(68d7deb16251beb9).(uicxx . . $ MemoryDumpPane#ui.->textEditcxx . . $ Ui_MemoryDumpPane#textEdit.->documentcxx . . $ QTextEdit#document(f21741221844491e).());
236 cursor.setPositioncxx . . $ QTextCursor#setPosition(f2a23d9eedd3abdd).(0);
237 lineNum = 0;
238 while (!list.isEmptycxx . . $ QList#isEmpty(3482b152b9333168).()) {
239 while (lineNum < list.firstcxx . . $ QList#first(19b2b6f17af048b).()) {
240 cursor.movePositioncxx . . $ QTextCursor#movePosition(e5e992d8a5d1c17e).(QTextCursorcxx . . $ QTextCursor#::NextBlockcxx . . $ QTextCursor#NextBlock.);
241 lineNum++;
242 }
243
244 memoryDumpLine =cxx . . $ QString#`operator=`(d02845eef0c33901). "";
245 byteNum = lineNum * 8;
246 memoryDumpLine.appendcxx . . $ QString#append(6a89d0b7f4d2681c).(QStringcxx . . $ QString#QString(85c52e162fed56f9).("%1 | ").argcxx . . $ QString#arg(64ab2ed17cc11715).(byteNum, 4, 16, QLatin1Charcxx . . $ QChar#QChar(a50889c09eec06d9).('0')).toUppercxx . . $ QString#toUpper(30b3b70527b1c61a).());
247 for (int j = 0; j < 8; j++) {
248 memoryDumpLine.appendcxx . . $ QString#append(6a89d0b7f4d2681c).(QStringcxx . . $ QString#QString(85c52e162fed56f9).("%1 ").argcxx . . $ QString#arg(64ab2ed17cc11715).(Simcxx . . $ Sim#::Memcxx . . $ Sim#Mem.[cxx . . $ QVector#`operator[]`(7a0ef1c7079e8533).byteNum++], 2, 16, QLatin1Charcxx . . $ QChar#QChar(a50889c09eec06d9).('0')).toUppercxx . . $ QString#toUpper(30b3b70527b1c61a).());
249 }
250 memoryDumpLine.appendcxx . . $ QString#append(d02845eef0c33901).("|");
251 byteNum = lineNum * 8;
252 for (int j = 0; j < 8; j++) {
253 ch =cxx . . $ QChar#`operator=`(81d7e7f12920c16). QCharcxx . . $ QChar#(Simcxx . . $ Sim#::Memcxx . . $ Sim#Mem.[cxx . . $ QVector#`operator[]`(7a0ef1c7079e8533).byteNum++]);
254 if (ch.isPrintcxx . . $ QChar#isPrint(3482b152b9333168).()) {
255 memoryDumpLine.appendcxx . . $ QString#append(3a2ffbdf8ecc25e2).(ch);
256 } else {
257 memoryDumpLine.appendcxx . . $ QString#append(d02845eef0c33901).(".");
258 }
259 }
260 cursor.movePositioncxx . . $ QTextCursor#movePosition(e5e992d8a5d1c17e).(QTextCursorcxx . . $ QTextCursor#::EndOfLinecxx . . $ QTextCursor#EndOfLine., QTextCursorcxx . . $ QTextCursor#::KeepAnchorcxx . . $ QTextCursor#KeepAnchor.);
261 uicxx . . $ MemoryDumpPane#ui.->textEditcxx . . $ Ui_MemoryDumpPane#textEdit.->setTextCursorcxx . . $ QTextEdit#setTextCursor(a408cee6726ac3d5).(cursor);
262 uicxx . . $ MemoryDumpPane#ui.->textEditcxx . . $ Ui_MemoryDumpPane#textEdit.->insertPlainTextcxx . . $ QTextEdit#insertPlainText(3520e46b33348bf6).(memoryDumpLine);
263 cursor.movePositioncxx . . $ QTextCursor#movePosition(e5e992d8a5d1c17e).(QTextCursorcxx . . $ QTextCursor#::NextBlockcxx . . $ QTextCursor#NextBlock.);
264 lineNum++;
265 list.removeFirstcxx . . $ QList#removeFirst(49f6e7a06ebc5aa8).();
266 }
267 modifiedBytescxx . . $ MemoryDumpPane#modifiedBytes..clearcxx . . $ QSet#clear(49f6e7a06ebc5aa8).();
268
269 uicxx . . $ MemoryDumpPane#ui.->textEditcxx . . $ Ui_MemoryDumpPane#textEdit.->verticalScrollBarcxx . . $ QAbstractScrollArea#verticalScrollBar(49d9510c6adf8c19).()->setValuecxx . . $ QAbstractSlider#setValue(d4f767463ce0a6b3).(vertScrollBarPosition);
270 uicxx . . $ MemoryDumpPane#ui.->textEditcxx . . $ Ui_MemoryDumpPane#textEdit.->horizontalScrollBarcxx . . $ QAbstractScrollArea#horizontalScrollBar(49d9510c6adf8c19).()->setValuecxx . . $ QAbstractSlider#setValue(d4f767463ce0a6b3).(horizScrollBarPosition);
271
272 }
273
274 void MemoryDumpPanecxx . . $ MemoryDumpPane#::scrollToTopcxx . . $ MemoryDumpPane#scrollToTop(49f6e7a06ebc5aa8).()
275 {
276 uicxx . . $ MemoryDumpPane#ui.->textEditcxx . . $ Ui_MemoryDumpPane#textEdit.->verticalScrollBarcxx . . $ QAbstractScrollArea#verticalScrollBar(49d9510c6adf8c19).()->setValuecxx . . $ QAbstractSlider#setValue(d4f767463ce0a6b3).(0);
277 uicxx . . $ MemoryDumpPane#ui.->textEditcxx . . $ Ui_MemoryDumpPane#textEdit.->horizontalScrollBarcxx . . $ QAbstractScrollArea#horizontalScrollBar(49d9510c6adf8c19).()->setValuecxx . . $ QAbstractSlider#setValue(d4f767463ce0a6b3).(0);
278 }
279
280 void MemoryDumpPanecxx . . $ MemoryDumpPane#::highlightOnFocuscxx . . $ MemoryDumpPane#highlightOnFocus(49f6e7a06ebc5aa8).()
281 {
282 if (uicxx . . $ MemoryDumpPane#ui.->textEditcxx . . $ Ui_MemoryDumpPane#textEdit.->hasFocuscxx . . $ QWidget#hasFocus(50ce9a9e25b4a850).() || uicxx . . $ MemoryDumpPane#ui.->scrollToLineEditcxx . . $ Ui_MemoryDumpPane#scrollToLineEdit.->hasFocuscxx . . $ QWidget#hasFocus(50ce9a9e25b4a850).()) {
283 uicxx . . $ MemoryDumpPane#ui.->labelcxx . . $ Ui_MemoryDumpPane#label.->setAutoFillBackgroundcxx . . $ QWidget#setAutoFillBackground(b45ddcbc8423892c).(true);
284 }
285 else {
286 uicxx . . $ MemoryDumpPane#ui.->labelcxx . . $ Ui_MemoryDumpPane#label.->setAutoFillBackgroundcxx . . $ QWidget#setAutoFillBackground(b45ddcbc8423892c).(false);
287 }
288 }
289
290 bool MemoryDumpPanecxx . . $ MemoryDumpPane#::hasFocuscxx . . $ MemoryDumpPane#hasFocus(c9857a73d68e59ba).()
291 {
292 return uicxx . . $ MemoryDumpPane#ui.->textEditcxx . . $ Ui_MemoryDumpPane#textEdit.->hasFocuscxx . . $ QWidget#hasFocus(50ce9a9e25b4a850).() || uicxx . . $ MemoryDumpPane#ui.->scrollToLineEditcxx . . $ Ui_MemoryDumpPane#scrollToLineEdit.->hasFocuscxx . . $ QWidget#hasFocus(50ce9a9e25b4a850).();
293 }
294
295 void MemoryDumpPanecxx . . $ MemoryDumpPane#::copycxx . . $ MemoryDumpPane#copy(49f6e7a06ebc5aa8).()
296 {
297 uicxx . . $ MemoryDumpPane#ui.->textEditcxx . . $ Ui_MemoryDumpPane#textEdit.->copycxx . . $ QTextEdit#copy(49f6e7a06ebc5aa8).();
298 }
299
300 int MemoryDumpPanecxx . . $ MemoryDumpPane#::memoryDumpWidthcxx . . $ MemoryDumpPane#memoryDumpWidth(b126dc7c1de90089).()
301 {
302 return uicxx . . $ MemoryDumpPane#ui.->textEditcxx . . $ Ui_MemoryDumpPane#textEdit.->documentcxx . . $ QTextEdit#document(f21741221844491e).()->documentLayoutcxx . . $ QTextDocument#documentLayout(135eff1e02365923).()->documentSizecxx . . $ QAbstractTextDocumentLayout#documentSize(6c9504dc925659fb).().toSizecxx . . $ QSizeF#toSize(31eef80d4686a819).().widthcxx . . $ QSize#width(ea6fe5115c70a13f).() +
303 uicxx . . $ MemoryDumpPane#ui.->textEditcxx . . $ Ui_MemoryDumpPane#textEdit.->verticalScrollBarcxx . . $ QAbstractScrollArea#verticalScrollBar(49d9510c6adf8c19).()->widthcxx . . $ QWidget#width(455f465bc33b4cdf).() + 6;
304 }
305
306 void MemoryDumpPanecxx . . $ MemoryDumpPane#::onFontChangedcxx . . $ MemoryDumpPane#onFontChanged(19c44da831d1de49).(QFontcxx . . $ QFont# font)
307 {
308 uicxx . . $ MemoryDumpPane#ui.->textEditcxx . . $ Ui_MemoryDumpPane#textEdit.->setFontcxx . . $ QWidget#setFont(d0a4bd0c8524b912).(font);
309 }
310
311 void MemoryDumpPanecxx . . $ MemoryDumpPane#::highlightBytecxx . . $ MemoryDumpPane#highlightByte(6f91d3f73a5b9054).(int memAddr, QColorcxx . . $ QColor# foreground, QColorcxx . . $ QColor# background)
312 {
313 QTextCursorcxx . . $ QTextCursor# cursorcxx . . $ QTextCursor#QTextCursor(68d7deb16251beb9).(uicxx . . $ MemoryDumpPane#ui.->textEditcxx . . $ Ui_MemoryDumpPane#textEdit.->documentcxx . . $ QTextEdit#document(f21741221844491e).());
314 cursor.setPositioncxx . . $ QTextCursor#setPosition(f2a23d9eedd3abdd).(0);
315 for (int i = 0; i < memAddr / 8; i++) {
316 cursor.movePositioncxx . . $ QTextCursor#movePosition(e5e992d8a5d1c17e).(QTextCursorcxx . . $ QTextCursor#::NextBlockcxx . . $ QTextCursor#NextBlock.);
317 }
318 for (int i = 0; i < 7 + 3 * (memAddr % 8); i++) {
319 cursor.movePositioncxx . . $ QTextCursor#movePosition(e5e992d8a5d1c17e).(QTextCursorcxx . . $ QTextCursor#::NextCharactercxx . . $ QTextCursor#NextCharacter.);
320 }
321 cursor.movePositioncxx . . $ QTextCursor#movePosition(e5e992d8a5d1c17e).(QTextCursorcxx . . $ QTextCursor#::NextCharactercxx . . $ QTextCursor#NextCharacter., QTextCursorcxx . . $ QTextCursor#::KeepAnchorcxx . . $ QTextCursor#KeepAnchor., 2);
322 QTextCharFormatcxx . . $ QTextCharFormat# formatcxx . . $ QTextCharFormat#QTextCharFormat(49f6e7a06ebc5aa8).;
323 format.setBackgroundcxx . . $ QTextFormat#setBackground(ffc9f5d0bda78261).(backgroundcxx . . $ QBrush#QBrush(b50947b0752ea6ac).);
324 format.setForegroundcxx . . $ QTextFormat#setForeground(ffc9f5d0bda78261).(foregroundcxx . . $ QBrush#QBrush(b50947b0752ea6ac).);
325 cursor.mergeCharFormatcxx . . $ QTextCursor#mergeCharFormat(dd8d5568386b23bd).(format);
326 }
327
328 void MemoryDumpPanecxx . . $ MemoryDumpPane#::mouseReleaseEventcxx . . $ MemoryDumpPane#mouseReleaseEvent(702858a82d06265c).(QMouseEventcxx . . $ QMouseEvent# *)
329 {
330 uicxx . . $ MemoryDumpPane#ui.->textEditcxx . . $ Ui_MemoryDumpPane#textEdit.->setFocuscxx . . $ QWidget#setFocus(49f6e7a06ebc5aa8).();
331 }
332
333 void MemoryDumpPanecxx . . $ MemoryDumpPane#::scrollToBytecxx . . $ MemoryDumpPane#scrollToByte(d4f767463ce0a6b3).(int byte)
334 {
335 int min = uicxx . . $ MemoryDumpPane#ui.->textEditcxx . . $ Ui_MemoryDumpPane#textEdit.->verticalScrollBarcxx . . $ QAbstractScrollArea#verticalScrollBar(49d9510c6adf8c19).()->minimumcxx . . $ QAbstractSlider#minimum(455f465bc33b4cdf).();
336 int max = uicxx . . $ MemoryDumpPane#ui.->textEditcxx . . $ Ui_MemoryDumpPane#textEdit.->verticalScrollBarcxx . . $ QAbstractScrollArea#verticalScrollBar(49d9510c6adf8c19).()->maximumcxx . . $ QAbstractSlider#maximum(455f465bc33b4cdf).();
337 uicxx . . $ MemoryDumpPane#ui.->textEditcxx . . $ Ui_MemoryDumpPane#textEdit.->verticalScrollBarcxx . . $ QAbstractScrollArea#verticalScrollBar(49d9510c6adf8c19).()->setValuecxx . . $ QAbstractSlider#setValue(d4f767463ce0a6b3).(min + static_cast<int>(8 * (byte / 4096 - 8) + ((byte - byte % 8) / 65536.0) * (max - min)));
338 }
339
340 void MemoryDumpPanecxx . . $ MemoryDumpPane#::scrollToPCcxx . . $ MemoryDumpPane#scrollToPC(49f6e7a06ebc5aa8).()
341 {
342 uicxx . . $ MemoryDumpPane#ui.->scrollToLineEditcxx . . $ Ui_MemoryDumpPane#scrollToLineEdit.->setTextcxx . . $ QLineEdit#setText(3520e46b33348bf6).(QStringcxx . . $ QString#QString(85c52e162fed56f9).("0x") +cxx . . $ operator+(fab9b4f80031f353). QStringcxx . . $ QString#QString(85c52e162fed56f9).("%1").argcxx . . $ QString#arg(64ab2ed17cc11715).(Simcxx . . $ Sim#::programCountercxx . . $ Sim#programCounter., 4, 16, QLatin1Charcxx . . $ QChar#QChar(a50889c09eec06d9).('0')).toUppercxx . . $ QString#toUpper(30b3b70527b1c61a).());
343 }
344
345 void MemoryDumpPanecxx . . $ MemoryDumpPane#::scrollToSPcxx . . $ MemoryDumpPane#scrollToSP(49f6e7a06ebc5aa8).()
346 {
347 uicxx . . $ MemoryDumpPane#ui.->scrollToLineEditcxx . . $ Ui_MemoryDumpPane#scrollToLineEdit.->setTextcxx . . $ QLineEdit#setText(3520e46b33348bf6).(QStringcxx . . $ QString#QString(85c52e162fed56f9).("0x") +cxx . . $ operator+(fab9b4f80031f353). QStringcxx . . $ QString#QString(85c52e162fed56f9).("%1").argcxx . . $ QString#arg(64ab2ed17cc11715).(Simcxx . . $ Sim#::stackPointercxx . . $ Sim#stackPointer., 4, 16, QLatin1Charcxx . . $ QChar#QChar(a50889c09eec06d9).('0')).toUppercxx . . $ QString#toUpper(30b3b70527b1c61a).());
348 }
349
350 void MemoryDumpPanecxx . . $ MemoryDumpPane#::scrollToAddresscxx . . $ MemoryDumpPane#scrollToAddress(7df51288a9ebd664).(QStringcxx . . $ QString# string)
351 {
352 bool ok;
353 int byte;
354 if (string.startsWithcxx . . $ QString#startsWith(8cce4688c16f48f3).("0x"cxx . . $ QString#QString(85c52e162fed56f9)., Qtcxx . . $ Qt/::CaseInsensitivecxx . . $ Qt/CaseInsensitive.)) {
355 byte = string.toIntcxx . . $ QString#toInt(d7972accae11ee1f).(&ok, 16);
356 if (ok) {
357 if (byte > 65535) {
358 uicxx . . $ MemoryDumpPane#ui.->scrollToLineEditcxx . . $ Ui_MemoryDumpPane#scrollToLineEdit.->setTextcxx . . $ QLineEdit#setText(3520e46b33348bf6).("0xFFFF"cxx . . $ QString#QString(85c52e162fed56f9).);
359 } else {
360 scrollToBytecxx . . $ MemoryDumpPane#scrollToByte(d4f767463ce0a6b3).(byte);
361 }
362 }
363 else {
364 uicxx . . $ MemoryDumpPane#ui.->scrollToLineEditcxx . . $ Ui_MemoryDumpPane#scrollToLineEdit.->setTextcxx . . $ QLineEdit#setText(3520e46b33348bf6).("0x"cxx . . $ QString#QString(85c52e162fed56f9).);
365 }
366 }
367 else {
368 uicxx . . $ MemoryDumpPane#ui.->scrollToLineEditcxx . . $ Ui_MemoryDumpPane#scrollToLineEdit.->setTextcxx . . $ QLineEdit#setText(3520e46b33348bf6).("0x"cxx . . $ QString#QString(85c52e162fed56f9).);
369 }
370
371 // else {
372 // byte = string.toInt(&ok, 10);
373 // if (ok) {
374 // if (byte < 0) {
375 // ui->scrollToLineEdit->setText("0");
376 // }
377 // else if (byte > 65535) {
378 // ui->scrollToLineEdit->setText("65535");
379 // } else {
380 // scrollToByte(byte);
381 // ui->scrollToLineEdit->setText(QString("%1").arg(byte));
382 // }
383 // }
384 // else {
385 // ui->scrollToLineEdit->setText("");
386 // }
387 // }
388 }