diff options
| author | Mason Reed <mason@vector35.com> | 2025-04-29 16:05:54 -0400 |
|---|---|---|
| committer | Mason Reed <mason@vector35.com> | 2025-05-06 21:08:42 -0400 |
| commit | f9ac7495ac089f32b1712e5500cf2cd0c426c5dc (patch) | |
| tree | 001fa4219b3952389f2e957a8cfdb3d85f7cc04d /ui | |
| parent | b0965fa2a5c703214f60a6c5af01f6ddf21e6f42 (diff) | |
Memory map UI improvements
Diffstat (limited to 'ui')
| -rw-r--r-- | ui/memorymap.h | 26 | ||||
| -rw-r--r-- | ui/uitypes.h | 1 |
2 files changed, 27 insertions, 0 deletions
diff --git a/ui/memorymap.h b/ui/memorymap.h index f96f26c0..9fdab8be 100644 --- a/ui/memorymap.h +++ b/ui/memorymap.h @@ -37,6 +37,30 @@ public: /*! + \ingroup memorymap +*/ +class BINARYNINJAUIAPI MemoryRegionDialog : public QDialog +{ + QPushButton* m_selectFileButton; + QPushButton* m_acceptButton; + QPushButton* m_cancelButton; + QLineEdit* m_nameField; + QLineEdit* m_startField; + QLineEdit* m_endField; + QLabel* m_contentsLabel; + + BinaryViewRef m_data; + SegmentRef m_segment; + std::optional<std::string> m_filePath; + + void SelectFile(); + void Submit(); +public: + MemoryRegionDialog(QWidget* parent, BinaryViewRef data, SegmentRef associatedSegment = nullptr); +}; + +/*! + \ingroup memorymap */ class BINARYNINJAUIAPI SegmentDialog : public QDialog @@ -92,6 +116,7 @@ enum class SegmentColumn : int { DATA_LENGTH, FLAGS, SOURCE, + REGION, COLUMN_COUNT, }; @@ -142,6 +167,7 @@ class BINARYNINJAUIAPI SegmentWidget : public QWidget QMenu* createHeaderContextMenu(const QPoint& p); void restoreDefaults(); + void addMemoryRegion(SegmentRef segment); void addSegment(); void editSegment(SegmentRef segment); void disableSegment(SegmentRef segment); diff --git a/ui/uitypes.h b/ui/uitypes.h index a520dbbe..89d2bdcd 100644 --- a/ui/uitypes.h +++ b/ui/uitypes.h @@ -99,6 +99,7 @@ typedef BinaryNinja::Ref<BinaryNinja::ScriptingProvider> ScriptingProviderRef; typedef BinaryNinja::Ref<BinaryNinja::SecretsProvider> SecretsProviderRef; typedef BinaryNinja::Ref<BinaryNinja::Section> SectionRef; typedef BinaryNinja::Ref<BinaryNinja::Segment> SegmentRef; +typedef BinaryNinja::Ref<BinaryNinja::MemoryMap> MemoryMapRef; typedef BinaryNinja::Ref<BinaryNinja::Settings> SettingsRef; typedef BinaryNinja::Ref<BinaryNinja::Snapshot> SnapshotRef; typedef BinaryNinja::Ref<BinaryNinja::Structure> StructureRef; |
