mirror of
https://github.com/RGBCube/serenity
synced 2025-07-25 00:07:34 +00:00
HackStudio: Allow changing variable values in debugger
This patch adds a context menu to variables in the debugger variable tree view that has an option to set the value of a variable. An input box will pop up asking for the new value of the variable, which is then parsed and used to set the actual variable.
This commit is contained in:
parent
ab40cc60d1
commit
75e42648e1
5 changed files with 108 additions and 14 deletions
|
@ -36,6 +36,8 @@ class VariablesModel final : public GUI::Model {
|
|||
public:
|
||||
static RefPtr<VariablesModel> create(const PtraceRegisters& regs);
|
||||
|
||||
void set_variable_value(const GUI::ModelIndex&, const StringView&, GUI::Window*);
|
||||
|
||||
virtual int row_count(const GUI::ModelIndex& = GUI::ModelIndex()) const override;
|
||||
virtual int column_count(const GUI::ModelIndex& = GUI::ModelIndex()) const override { return 1; }
|
||||
virtual GUI::Variant data(const GUI::ModelIndex& index, Role role = Role::Display) const override;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue