2019-03-27 08:24:54 +00:00
|
|
|
#ifndef MEMORYDOCKWIDGET_H
|
|
|
|
#define MEMORYDOCKWIDGET_H
|
|
|
|
|
|
|
|
#include "CutterDockWidget.h"
|
|
|
|
#include "core/Cutter.h"
|
|
|
|
|
2019-06-18 13:02:41 +00:00
|
|
|
class CutterSeekable;
|
|
|
|
|
2019-07-19 19:21:12 +00:00
|
|
|
/* Disassembly/Graph/Hexdump/Pseudocode view priority */
|
|
|
|
enum class MemoryWidgetType { Disassembly, Graph, Hexdump, Pseudocode };
|
|
|
|
|
2019-03-27 08:24:54 +00:00
|
|
|
class MemoryDockWidget : public CutterDockWidget
|
|
|
|
{
|
|
|
|
Q_OBJECT
|
|
|
|
public:
|
2019-07-19 19:21:12 +00:00
|
|
|
MemoryDockWidget(MemoryWidgetType type, MainWindow *parent, QAction *action = nullptr);
|
2019-03-27 08:24:54 +00:00
|
|
|
~MemoryDockWidget() {}
|
|
|
|
|
2019-06-18 13:02:41 +00:00
|
|
|
CutterSeekable* getSeekable() const;
|
|
|
|
|
2019-07-19 19:21:12 +00:00
|
|
|
bool tryRaiseMemoryWidget();
|
|
|
|
void raiseMemoryWidget();
|
|
|
|
MemoryWidgetType getType() const
|
|
|
|
{
|
|
|
|
return mType;
|
|
|
|
}
|
|
|
|
bool eventFilter(QObject *object, QEvent *event);
|
2019-03-27 08:24:54 +00:00
|
|
|
private:
|
|
|
|
|
2019-07-19 19:21:12 +00:00
|
|
|
MemoryWidgetType mType;
|
2019-06-18 13:02:41 +00:00
|
|
|
|
|
|
|
public slots:
|
|
|
|
void updateWindowTitle();
|
|
|
|
|
|
|
|
protected:
|
|
|
|
CutterSeekable *seekable = nullptr;
|
|
|
|
|
|
|
|
virtual QString getWindowTitle() const = 0;
|
2019-03-27 08:24:54 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
#endif // MEMORYDOCKWIDGET_H
|