summaryrefslogtreecommitdiff
path: root/ui/createarraydialog.h
diff options
context:
space:
mode:
authorAlexander Taylor <alex@vector35.com>2023-05-30 15:53:53 -0400
committerAlexander Taylor <alex@vector35.com>2023-05-30 15:53:53 -0400
commitc93c7da513c27a7693f045d614da081fda9f635f (patch)
treecb33e56863a6127140281045520158ec9474f1ae /ui/createarraydialog.h
parentd2877cfdea1ee2f960b014de5ad07c6a352da4c4 (diff)
Cleaned up the Create Array Dialog.
Diffstat (limited to 'ui/createarraydialog.h')
-rw-r--r--ui/createarraydialog.h16
1 files changed, 8 insertions, 8 deletions
diff --git a/ui/createarraydialog.h b/ui/createarraydialog.h
index d14bbca3..1f1114d7 100644
--- a/ui/createarraydialog.h
+++ b/ui/createarraydialog.h
@@ -16,33 +16,33 @@ class CreateArrayDialog : public QDialog
uint64_t m_elementCount;
QLineEdit* m_startField;
- QComboBox* m_countTypeDropdown;
QComboBox* m_typeDropdown;
- QSpinBox* m_countField;
+ QLineEdit* m_countField;
- QPushButton* m_acceptButton;
+ QPushButton* m_cancelButton;
+ QPushButton* m_createButton;
void validate();
public:
- CreateArrayDialog(BinaryViewRef data, QWidget* parent = nullptr);
+ explicit CreateArrayDialog(BinaryViewRef data, QWidget* parent = nullptr);
/// Set the initial start address, element type, and element count for
/// the dialog. The element type may be null if no default is desired; a
/// default will be chosen by the dialog.
- void setInitialState(uint64_t start, TypeRef elementType, uint64_t count);
+ void setInitialState(uint64_t start, const TypeRef& elementType, uint64_t count);
/// Get the desired start address from the accepted dialog.
- uint64_t startAddress() const;
+ [[nodiscard]] uint64_t startAddress() const;
/// Get the desired array element type from the accepted dialog.
///
/// The returned value will NOT be of `Type::ArrayType(...)`, but rather
/// the element inside.
- TypeRef elementType() const;
+ [[nodiscard]] TypeRef elementType() const;
/// Get the desired element count from the accepted dialog.
- uint64_t elementCount() const;
+ [[nodiscard]] uint64_t elementCount() const;
void accept() override;
void reject() override;