Commit ebccd4c0 authored by hjk's avatar hjk
Browse files

debugger: fix manual reload of registers

parent bbe3bab2
......@@ -231,7 +231,7 @@ public slots:
public slots: // FIXME
void showDebuggerOutput(const QString &msg)
{ showDebuggerOutput(LogDebug, msg); }
private slots:
//private slots: // FIXME
void showDebuggerOutput(int channel, const QString &msg);
void showDebuggerInput(int channel, const QString &msg);
void showApplicationOutput(const QString &data);
......
......@@ -144,8 +144,7 @@ private:
///////////////////////////////////////////////////////////////////////
RegisterWindow::RegisterWindow(DebuggerManager *manager)
: m_manager(manager), m_alwaysResizeColumnsToContents(true),
m_alwaysReloadContents(false)
: m_manager(manager), m_alwaysResizeColumnsToContents(true)
{
QAction *act = theDebuggerAction(UseAlternatingRowColors);
setWindowTitle(tr("Registers"));
......@@ -167,9 +166,6 @@ void RegisterWindow::contextMenuEvent(QContextMenuEvent *ev)
QMenu menu;
QAction *actReload = menu.addAction(tr("Reload register listing"));
QAction *actAlwaysReload = menu.addAction(tr("Always reload register listing"));
actAlwaysReload->setCheckable(true);
actAlwaysReload->setChecked(m_alwaysReloadContents);
menu.addSeparator();
QModelIndex idx = indexAt(ev->pos());
......@@ -214,9 +210,7 @@ void RegisterWindow::contextMenuEvent(QContextMenuEvent *ev)
else if (act == actAlwaysAdjust)
setAlwaysResizeColumnsToContents(!m_alwaysResizeColumnsToContents);
else if (act == actReload)
reloadContents();
else if (act == actAlwaysReload)
setAlwaysReloadContents(!m_alwaysReloadContents);
m_manager->reloadRegisters();
else if (act == actShowMemory)
(void) new MemoryViewAgent(m_manager, address);
else if (act) {
......@@ -240,18 +234,6 @@ void RegisterWindow::setAlwaysResizeColumnsToContents(bool on)
header()->setResizeMode(1, mode);
}
void RegisterWindow::setAlwaysReloadContents(bool on)
{
m_alwaysReloadContents = on;
if (m_alwaysReloadContents)
reloadContents();
}
void RegisterWindow::reloadContents()
{
emit reloadRegisterRequested();
}
void RegisterWindow::setModel(QAbstractItemModel *model)
{
......
......@@ -44,14 +44,9 @@ public:
explicit RegisterWindow(DebuggerManager *manager);
void setModel(QAbstractItemModel *model);
signals:
void reloadRegisterRequested();
public slots:
void resizeColumnsToContents();
void setAlwaysResizeColumnsToContents(bool on);
void reloadContents();
void setAlwaysReloadContents(bool on);
void setAlternatingRowColorsHelper(bool on) { setAlternatingRowColors(on); }
private:
......@@ -61,7 +56,6 @@ private:
DebuggerManager *m_manager;
bool m_alwaysResizeColumnsToContents;
bool m_alwaysReloadContents;
};
} // namespace Internal
......
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