12 #include "../models/DisassemblyModel.h" 30 get_style_context()->add_class(
"disassemblyContainer");
41 for (
long unsigned int i = 0; i <
rows.size(); i++) {
88 : Box(Gtk::Orientation::ORIENTATION_HORIZONTAL, 0) {
102 get_style_context()->add_class(
"disassemblyRows");
104 set_focus_on_click(
true);
114 breakpoint.get_style_context()->add_class(
"breakpointButtons");
115 breakpoint.set_tooltip_text(
"Toggle breakpoint");
122 address.get_style_context()->add_class(
"disassemblyLabels");
123 address.set_size_request(100, 10);
130 hex.get_style_context()->add_class(
"disassemblyLabels");
131 hex.set_size_request(100, 10);
138 disassembly.get_style_context()->add_class(
"disassemblyLabels");
153 breakpoint.set_state_flags(Gtk::STATE_FLAG_CHECKED);
155 breakpoint.set_state_flags(Gtk::STATE_FLAG_NORMAL);
222 (Gtk::STATE_FLAG_CHECKED | Gtk::STATE_FLAG_DIR_LTR);
void setAddressVal(const uint32_t val)
Set the value of addressVal member.
void setModel(DisassemblyModel *const val)
Sets the value of the model member.
DisassemblyView(MainWindowView *const parent)
Construct a new DisassemblyView::DisassemblyView object.
The declaration of the DisassemblyModel class.
DisassemblyModel * model
A pointer to the related model.
uint32_t addressVal
The address pointed to, as an integer.
DisassemblyRows()
Construct a new DisassemblyRows::DisassemblyRows object.
void initDisassemblyRows()
Packs the 13 disassemblyRows into their container and gives them a pointer to the DisassemblyModel ob...
const std::string getAddress() const
Get the text in the address box.
Gtk::Label address
Displays the address of the current memory value.
void initDisassemblyContainer()
Initialises the containers & their children - packs children into containers, sets sizes and layouts...
std::vector< DisassemblyRows > *const getRows()
Gets a pointer to the rows of views.
void setDisassembly(const std::string text)
Set the text of disassembly label.
void initHex()
Initialises the hex label.
Gtk::Label disassembly
Displays the current disassembly value of the memory.
const bool getBreakpoint()
Returns if a breakpoint is set or not.
void setBreakpoint(const bool text)
Set the state of the breakpoint button. This is a little unusual - it sets the state in terms of CSS ...
The class definition of the main window of the program. This main window is the mater view of the pro...
DisassemblyModel * model
A pointer to the model.
Gtk::HBox buttonSizer
Setting exact size of widgets is hard; this container is needed to set the size of the button...
MainWindowView *const getParent() const
Return a constant pointer to the parent member.
void initAddress()
Initialises the address label.
void setAddress(const std::string text)
Set the text of the address label.
void initBreakpoint()
Initialises the breakpoint button.
MainWindowView *const parent
A pointer to the parent view.
DisassemblyModel *const getModel() const
Gets a constant pointer to the model member.
Gtk::ToggleButton *const getButton()
Gets a constant pointer to the breakpoint button member.
std::vector< DisassemblyRows > rows
An array of row views. Each array entry represents a row of memory values within the memory window...
void initDisassembly()
Initialises the disassembly label.
Gtk::Label hex
Displays the current hexadecimal value of the memory.
void setModel(DisassemblyModel *const val)
Sets the value of the model pointer.
This file contains the header file for the DisassemblyRows and DisassemblyView classes.
Gtk::VButtonBox disassemblyContainer
A container for the disassembly rows.
const std::string getDisassembly()
Gets the disassembly text for the breakpoint row.
void setHex(const std::string text)
Set the text of the hex label.
Gtk::ToggleButton breakpoint
The debugging breakpoint button.
const uint32_t getAddressVal() const
Get the addressVal member.