2017-03-29 10:18:37 +00:00
|
|
|
#ifndef XREFSDIALOG_H
|
|
|
|
#define XREFSDIALOG_H
|
|
|
|
|
|
|
|
#include "highlighter.h"
|
2017-06-07 10:56:55 +00:00
|
|
|
#include "qrcore.h"
|
2017-03-29 10:18:37 +00:00
|
|
|
|
|
|
|
#include <QDialog>
|
|
|
|
#include <QTreeWidgetItem>
|
|
|
|
|
|
|
|
class MainWindow;
|
|
|
|
|
2017-04-09 19:55:06 +00:00
|
|
|
namespace Ui
|
|
|
|
{
|
|
|
|
class XrefsDialog;
|
2017-03-29 10:18:37 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
class XrefsDialog : public QDialog
|
|
|
|
{
|
|
|
|
Q_OBJECT
|
|
|
|
|
|
|
|
public:
|
|
|
|
explicit XrefsDialog(MainWindow *main, QWidget *parent = 0);
|
|
|
|
~XrefsDialog();
|
|
|
|
|
2017-06-07 15:48:36 +00:00
|
|
|
void fillRefsForFunction(RVA addr, QString name);
|
2017-03-29 10:18:37 +00:00
|
|
|
|
|
|
|
private slots:
|
|
|
|
|
|
|
|
void on_fromTreeWidget_itemDoubleClicked(QTreeWidgetItem *item, int column);
|
|
|
|
|
|
|
|
void on_toTreeWidget_itemDoubleClicked(QTreeWidgetItem *item, int column);
|
|
|
|
|
|
|
|
QString normalizeAddr(QString addr);
|
|
|
|
|
|
|
|
void highlightCurrentLine();
|
|
|
|
void on_fromTreeWidget_itemSelectionChanged();
|
|
|
|
|
|
|
|
void on_toTreeWidget_itemSelectionChanged();
|
|
|
|
|
|
|
|
private:
|
2017-06-07 19:35:38 +00:00
|
|
|
RVA addr;
|
|
|
|
QString func_name;
|
|
|
|
|
2017-03-29 10:18:37 +00:00
|
|
|
Ui::XrefsDialog *ui;
|
|
|
|
MainWindow *main;
|
|
|
|
|
|
|
|
Highlighter *highlighter;
|
|
|
|
|
2017-06-07 19:35:38 +00:00
|
|
|
void fillRefs(QList<XrefDescription> refs, QList<XrefDescription> xrefs);
|
2017-06-07 15:48:36 +00:00
|
|
|
void updateLabels(QString name);
|
2017-06-07 19:35:38 +00:00
|
|
|
void updatePreview(RVA addr);
|
2017-06-07 15:48:36 +00:00
|
|
|
|
2017-03-29 10:18:37 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
#endif // XREFSDIALOG_H
|