work save
This commit is contained in:
parent
2ece0fa403
commit
71f5a7c056
|
@ -1159,7 +1159,16 @@ AnnotationType DebugReader::peekNextAnnotation()
|
||||||
return result;
|
return result;
|
||||||
}
|
}
|
||||||
|
|
||||||
void DebugReader::processDebugOutput()
|
void DebugReader::processResultRecord(const QString &line)
|
||||||
|
{
|
||||||
|
if (line.startsWith("^exit")) {
|
||||||
|
doprocessexited = true;
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
void DebugReader::processDebugOutput(const QString& debugOutput)
|
||||||
{
|
{
|
||||||
// Only update once per update at most
|
// Only update once per update at most
|
||||||
//WatchView.Items.BeginUpdate;
|
//WatchView.Items.BeginUpdate;
|
||||||
|
@ -1186,13 +1195,11 @@ void DebugReader::processDebugOutput()
|
||||||
doupdatecpuwindow = false;
|
doupdatecpuwindow = false;
|
||||||
doreceivedsfwarning = false;
|
doreceivedsfwarning = false;
|
||||||
|
|
||||||
QStringList lines = TextToLines(mOutput);
|
QStringList lines = TextToLines(debugOutput);
|
||||||
|
|
||||||
mOutputLine = 0;
|
for (int i=0;i<lines.count();i++) {
|
||||||
while (mOutputLine<lines.length()) {
|
QString line = lines[i];
|
||||||
QString line = lines[mOutputLine];
|
|
||||||
line = removeToken(line);
|
line = removeToken(line);
|
||||||
mOutputLine++;
|
|
||||||
if (line.isEmpty()) {
|
if (line.isEmpty()) {
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
|
@ -1203,8 +1210,12 @@ void DebugReader::processDebugOutput()
|
||||||
//todo: process console stream output
|
//todo: process console stream output
|
||||||
break;
|
break;
|
||||||
case '^': // result record
|
case '^': // result record
|
||||||
case '
|
processResultRecord(line);
|
||||||
|
break;
|
||||||
|
case '*': // exec async output
|
||||||
|
case '+': // status async output
|
||||||
|
case '=': // notify async output
|
||||||
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -1715,8 +1726,7 @@ void DebugReader::run()
|
||||||
buffer += readed;
|
buffer += readed;
|
||||||
|
|
||||||
if ( readed.endsWith("\r\n")&& outputTerminated(buffer)) {
|
if ( readed.endsWith("\r\n")&& outputTerminated(buffer)) {
|
||||||
mOutput = QString::fromUtf8(buffer);
|
processDebugOutput(QString::fromUtf8(buffer));
|
||||||
processDebugOutput();
|
|
||||||
buffer.clear();
|
buffer.clear();
|
||||||
mCmdRunning = false;
|
mCmdRunning = false;
|
||||||
runNextCmd();
|
runNextCmd();
|
||||||
|
|
|
@ -324,7 +324,9 @@ private:
|
||||||
void handleSource();
|
void handleSource();
|
||||||
void handleValueHistoryValue();
|
void handleValueHistoryValue();
|
||||||
AnnotationType peekNextAnnotation();
|
AnnotationType peekNextAnnotation();
|
||||||
void processDebugOutput();
|
|
||||||
|
void processResultRecord(const QString& line);
|
||||||
|
void processDebugOutput(const QString& debugOutput);
|
||||||
QString processEvalOutput();
|
QString processEvalOutput();
|
||||||
void processWatchOutput(PWatchVar WatchVar);
|
void processWatchOutput(PWatchVar WatchVar);
|
||||||
void runNextCmd();
|
void runNextCmd();
|
||||||
|
@ -352,7 +354,6 @@ private:
|
||||||
int mIndex;
|
int mIndex;
|
||||||
int mBreakPointLine;
|
int mBreakPointLine;
|
||||||
QString mBreakPointFile;
|
QString mBreakPointFile;
|
||||||
QString mOutput;
|
|
||||||
QString mEvalValue;
|
QString mEvalValue;
|
||||||
QStringList mMemoryValue;
|
QStringList mMemoryValue;
|
||||||
QStringList mLocalsValue;
|
QStringList mLocalsValue;
|
||||||
|
@ -374,7 +375,6 @@ private:
|
||||||
|
|
||||||
bool mStop;
|
bool mStop;
|
||||||
|
|
||||||
int mOutputLine;
|
|
||||||
friend class Debugger;
|
friend class Debugger;
|
||||||
// QThread interface
|
// QThread interface
|
||||||
protected:
|
protected:
|
||||||
|
|
Loading…
Reference in New Issue