KoMo2  1.0.0
A modern ARM emulator GUI.
CompileLoadView.h
Go to the documentation of this file.
1 
9 #include <gtkmm/button.h>
10 #include <gtkmm/buttonbox.h>
11 #include <gtkmm/label.h>
12 
13 class MainWindowView;
14 class CompileLoadModel;
15 
22 class CompileLoadView : public Gtk::VButtonBox {
23  public:
24  // Constructors and destructors
26 
27  // Getters and setters
28  Gtk::Button* const getCompileAndLoadButton();
29  Gtk::Button* const getBrowseButton();
30  Gtk::Label* const getSelectedFileLabel();
31  void setSelectedFileLabelText(const std::string val);
32  void setModel(CompileLoadModel* const val);
33 
34  private:
39 
44 
49  Gtk::Label selectedFileLabel;
50 
55  Gtk::Button compileAndLoadButton;
56 
60  Gtk::Button browseButton;
61 
62  // General functions
64  void initBrowseButton();
66  void initSelectedFileLabel();
67 
68  // ! Deleted special member functions
69  // stops these functions from being misused, creates a sensible error
70  CompileLoadView(const CompileLoadView&) = delete;
71  CompileLoadView(const CompileLoadView&&) = delete;
72  CompileLoadView& operator=(const CompileLoadView&) = delete;
73  CompileLoadView& operator=(const CompileLoadView&&) = delete;
74 };
CompileLoadModel * model
A pointer to the related model.
Gtk::Button compileAndLoadButton
A button which, when clicked, will read a .s file, compile it to .kmd, and the load it into Jimulator...
CompileLoadView(MainWindowView *const parent)
Construct a new CompileLoadView.
void setModel(CompileLoadModel *const val)
Set the model pointer.
void initSelectedFileLabel()
Sets up the initial information about the selected file label.
MainWindowView *const parent
A pointer to the parent view.
The class definition of the main window of the program. This main window is the mater view of the pro...
the class definition of the compileLoadModel class, a data model which encapsulates any statefullness...
Gtk::Button browseButton
A button which allows you to browse the file system for .s files.
void initCompileAndLoadButton()
Sets up the initial information about the compile & load button.
Gtk::Label selectedFileLabel
A label which displays whatever file has been selected by the browse button, to be compiled & loaded...
Gtk::Button *const getCompileAndLoadButton()
Gets the compileAndLoadButton member variable.
Gtk::Button *const getBrowseButton()
Gets the browseButton member variable.
void initBrowseButton()
Sets up the initial information about the browse file button.
Gtk::Label *const getSelectedFileLabel()
Gets the selectedFileLabel member variable.
void setSelectedFileLabelText(const std::string val)
Sets the text displayed by the selectedFileLabel member variable.
This class represents the visual aspects that make up the compile & load section of the KoMo2 GUI...
void initSelectAndLoadContainer()
Packs children into the compileLoadView, and sets its layout and size.