Commit 226e5906 authored by Victor Yacovlev's avatar Victor Yacovlev

Removed legacy code

parent b483661e
......@@ -14,7 +14,6 @@ set(SOURCES
terminal_plane.cpp
tabbar.cpp
aboutdialog.cpp
debuggerwindow.cpp
statusbar.cpp
debuggerview.cpp
)
......@@ -41,7 +40,6 @@ set(MOC_HEADERS
tabbar.h
aboutdialog.h
tabwidgetelement.h
debuggerwindow.h
statusbar.h
debuggerview.h
)
......
This diff is collapsed.
#ifndef COREGUI_DEBUGGERWINDOW_H
#define COREGUI_DEBUGGERWINDOW_H
#include <QtCore>
#include <QtGui>
#include "interfaces/runinterface.h"
namespace CoreGUI {
class DebuggerWindow : public QTreeWidget
{
Q_OBJECT
public:
explicit DebuggerWindow(Shared::RunInterface * runner, QWidget *parent = 0);
signals:
public slots:
/** Clear debugger window */
void reset();
/** Set globals frame */
void setGlobals(
/** module name */ const QString & moduleName,
/** variable names */ const QStringList & names,
/** variable base types */const QStringList & baseTypes,
/** variable dimensions */ const QList<int> & dimensions
);
/** Push a new stack frame */
void pushContext(
/** context header */ const QString & contextName,
/** variable names */ const QStringList & names,
/** variable base types */const QStringList & baseTypes,
/** variable dimensions */ const QList<int> & dimensions
);
/** Pop a stack frame */
void popContext();
/** Force update values */
void updateAllValues();
/** Update scalar variable value */
void updateLocalVariable(
/** variable name */ const QString & name,
/** value */ const QString & value
);
void updateGlobalVariable(
/** module qualified name */const QString & moduleName,
/** variable name */ const QString & name,
/** value */ const QString & value
);
/** Set table variable bounds */
void updateLocalTableBounds(
/** variable name */ const QString & name,
/** a list of bound pairs */ const QList<int> & bounds
);
void updateGlobalTableBounds(
/** module name */ const QString & moduleName,
/** variable name */ const QString & name,
/** a list of bound pairs */ const QList<int> & bounds
);
void setLocalReference(
/** variable name */ const QString & name,
/** target name */ const QString & targetName,
/** target array indeces */const QList<int> & indeces,
/** stack frames back, or -1 for global */ int back,
/** global value module name */ const QString & moduleName
);
/** Marks a table to redraw shown values */
void updateLocalTableValue(
/** variable name */ const QString & name,
/** indeces */ const QList<int> & indeces
);
void updateGlobalTableValue(
/** module name */ const QString & moduleName,
/** variable name */ const QString & name,
/** indeces */ const QList<int> & indeces
);
private slots:
void handleItemExpanded(QTreeWidgetItem * item);
void handleItemCollapsed(QTreeWidgetItem * item);
private:
void paintEvent(QPaintEvent *event);
void findExpandedTableItem(
const QList<int> & indeces,
QTreeWidgetItem * & item
);
static QString boundsToText(const QList<int> & bounds);
static int optimalGroupSize(int size);
static void valuesListToString(
const QVariant & vals,
int maxItems,
int & counter,
QString & result
);
void setupTableValue(QTreeWidgetItem * item);
QMap<QString,QTreeWidgetItem *> globals;
Shared::RunInterface * runner;
};
} // namespace CoreGUI
#endif // COREGUI_DEBUGGERWINDOW_H
......@@ -2,7 +2,6 @@
#include "extensionsystem/pluginmanager.h"
#include "interfaces/actorinterface.h"
#include "dataformats/ast_algorhitm.h"
#include "debuggerwindow.h"
#include "interfaces/coursesinterface.h"
namespace CoreGUI {
......@@ -28,7 +27,6 @@ KumirProgram::KumirProgram(QObject *parent)
, a_stop(0)
, gr_actions(0)
, w_mainWidget(0)
, w_debuggerWindow(0)
{
b_blind = false;
courseManagerRequest_ = false;
......@@ -196,7 +194,6 @@ void KumirProgram::setBytecodeRun(KPlugin *run)
void KumirProgram::fastRun()
{
if (w_debuggerWindow) w_debuggerWindow->reset();
b_processUserTerminated = false;
s_endStatus = "";
if (e_state!=Idle) {
......@@ -260,7 +257,6 @@ void KumirProgram::fastRun()
void KumirProgram::blindRun()
{
if (w_debuggerWindow) w_debuggerWindow->reset();
if (e_state==FastRun)
return;
b_blind = true;
......@@ -277,7 +273,6 @@ void KumirProgram::blindRun()
void KumirProgram::testingRun()
{
if (w_debuggerWindow) w_debuggerWindow->reset();
if (e_state==FastRun)
return;
......@@ -306,7 +301,6 @@ void KumirProgram::testingRun()
void KumirProgram::regularRun()
{
if (w_debuggerWindow) w_debuggerWindow->reset();
if (e_state==FastRun)
return;
b_blind = false;
......@@ -332,7 +326,6 @@ void KumirProgram::prepareKumirRunner(Shared::GeneratorInterface::DebugLevel deb
bool ok = false;
QString exeFileName;
if (analizer->resultType() == AnalizerInterface::RT_AST) {
if (w_debuggerWindow) w_debuggerWindow->reset();
ok = true;
bool mustRegenerate = !m_ast->lastModified.isValid() ||
!runner->loadedProgramVersion().isValid() ||
......@@ -423,7 +416,6 @@ void KumirProgram::stop()
b_processUserTerminated = true;
m_process->kill();
}
if (w_debuggerWindow) w_debuggerWindow->reset();
}
......@@ -476,7 +468,6 @@ void KumirProgram::handleRunnerStopped(int rr)
e_state = Idle;
m_terminal->clearFocus();
plugin_editor->unhighlightLine(documentId_);
if (w_debuggerWindow) w_debuggerWindow->reset();
}
typedef Shared::CoursesInterface CI;
......
......@@ -91,7 +91,6 @@ private:
int i_timerId;
QWidget * w_mainWidget;
bool b_processUserTerminated;
class DebuggerWindow * w_debuggerWindow;
};
} // namespace CoreGui
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment