OpenASIP 2.2
Loading...
Searching...
No Matches
Public Member Functions | List of all members
HighlightTopExecCountsCmd Class Reference

#include <HighlightTopExecCountsCmd.hh>

Inheritance diagram for HighlightTopExecCountsCmd:
Inheritance graph
Collaboration diagram for HighlightTopExecCountsCmd:
Collaboration graph

Public Member Functions

 HighlightTopExecCountsCmd ()
 
virtual ~HighlightTopExecCountsCmd ()
 
virtual bool Do ()
 
virtual int id () const
 
virtual HighlightTopExecCountsCmdcreate () const
 
virtual std::string icon () const
 
virtual bool isEnabled ()
 
- Public Member Functions inherited from GUICommand
 GUICommand (std::string name, wxWindow *parent)
 
virtual ~GUICommand ()
 
virtual bool isChecked () const
 
virtual std::string shortName () const
 
void setParentWindow (wxWindow *view)
 
wxWindow * parentWindow () const
 
std::string name () const
 

Detailed Description

Command for highlighting instructions with top execution counts in the disassembly window.

Definition at line 42 of file HighlightTopExecCountsCmd.hh.

Constructor & Destructor Documentation

◆ HighlightTopExecCountsCmd()

HighlightTopExecCountsCmd::HighlightTopExecCountsCmd ( )

The Constructor.

Definition at line 44 of file HighlightTopExecCountsCmd.cc.

44 :
45 GUICommand("Highlight Top Execution Counts", NULL) {
46
47 }

Referenced by create().

◆ ~HighlightTopExecCountsCmd()

HighlightTopExecCountsCmd::~HighlightTopExecCountsCmd ( )
virtual

The Destructor.

Definition at line 52 of file HighlightTopExecCountsCmd.cc.

52 {
53}

Member Function Documentation

◆ create()

HighlightTopExecCountsCmd * HighlightTopExecCountsCmd::create ( ) const
virtual

Creates and returns a new isntance of this command.

Returns
Newly created instance of this command.

Implements GUICommand.

Definition at line 101 of file HighlightTopExecCountsCmd.cc.

References HighlightTopExecCountsCmd().

Here is the call graph for this function:

◆ Do()

bool HighlightTopExecCountsCmd::Do ( )
virtual

Executes the command.

Implements GUICommand.

Definition at line 60 of file HighlightTopExecCountsCmd.cc.

60 {
62 assert(window != NULL);
63 DisasmTopCountAttrProvider* attrProvider =
65
66 if (ProximToolbox::frontend()->isProgramLoaded()) {
67 attrProvider->update();
68 }
69 window->setMoveAttrProvider(attrProvider);
70 window->Refresh();
71 return true;
72}
#define assert(condition)
void setMoveAttrProvider(ProximDisasmAttrProvider *attrProvider)
static TracedSimulatorFrontend * frontend()
static ProximDisassemblyWindow * disassemblyWindow()

References assert, ProximToolbox::disassemblyWindow(), ProximToolbox::frontend(), ProximDisassemblyWindow::setMoveAttrProvider(), and DisasmTopCountAttrProvider::update().

Here is the call graph for this function:

◆ icon()

std::string HighlightTopExecCountsCmd::icon ( ) const
virtual

Returns full path to the command icon file.

Returns
Full path to the command icon file.

Implements GUICommand.

Definition at line 81 of file HighlightTopExecCountsCmd.cc.

81 {
82 return "clear_console.png";
83}

◆ id()

int HighlightTopExecCountsCmd::id ( ) const
virtual

Returns ID of this command.

Implements GUICommand.

Definition at line 90 of file HighlightTopExecCountsCmd.cc.

References ProximConstants::COMMAND_HIGHLIGHT_TOP_EXEC_COUNTS.

◆ isEnabled()

bool HighlightTopExecCountsCmd::isEnabled ( )
virtual

Returns true if the command is enabled, false otherwise.

Returns
True if the console window exists.

Implements GUICommand.

Definition at line 112 of file HighlightTopExecCountsCmd.cc.

112 {
113 if (ProximToolbox::frontend()->isProgramLoaded()) {
114 return true;
115 } else {
116 return false;
117 }
118}

References ProximToolbox::frontend().

Here is the call graph for this function:

The documentation for this class was generated from the following files: