OpenASIP  2.0
Public Member Functions | List of all members
ClearDisassemblyHighlightCmd Class Reference

#include <ClearDisassemblyHighlightCmd.hh>

Inheritance diagram for ClearDisassemblyHighlightCmd:
Inheritance graph
Collaboration diagram for ClearDisassemblyHighlightCmd:
Collaboration graph

Public Member Functions

 ClearDisassemblyHighlightCmd ()
 
virtual ~ClearDisassemblyHighlightCmd ()
 
virtual bool Do ()
 
virtual int id () const
 
virtual ClearDisassemblyHighlightCmdcreate () 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 clearing disassembly window highlighting mode.

Definition at line 41 of file ClearDisassemblyHighlightCmd.hh.

Constructor & Destructor Documentation

◆ ClearDisassemblyHighlightCmd()

ClearDisassemblyHighlightCmd::ClearDisassemblyHighlightCmd ( )

The Constructor.

Definition at line 43 of file ClearDisassemblyHighlightCmd.cc.

43  :
44  GUICommand("Clear Disassembly highlight", NULL) {
45 
46  }

Referenced by create().

◆ ~ClearDisassemblyHighlightCmd()

ClearDisassemblyHighlightCmd::~ClearDisassemblyHighlightCmd ( )
virtual

The Destructor.

Definition at line 51 of file ClearDisassemblyHighlightCmd.cc.

51  {
52 }

Member Function Documentation

◆ create()

ClearDisassemblyHighlightCmd * ClearDisassemblyHighlightCmd::create ( ) const
virtual

Creates and returns a new isntance of this command.

Returns
Newly created instance of this command.

Implements GUICommand.

Definition at line 94 of file ClearDisassemblyHighlightCmd.cc.

94  {
95  return new ClearDisassemblyHighlightCmd();
96 }

References ClearDisassemblyHighlightCmd().

Here is the call graph for this function:

◆ Do()

bool ClearDisassemblyHighlightCmd::Do ( )
virtual

Executes the command.

Implements GUICommand.

Definition at line 59 of file ClearDisassemblyHighlightCmd.cc.

59  {
61  assert(window != NULL);
62  window->setMoveAttrProvider(NULL);
63  window->Refresh();
64  return true;
65 }

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

Here is the call graph for this function:

◆ icon()

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

Returns full path to the command icon file.

Returns
Full path to the command icon file.

Implements GUICommand.

Definition at line 74 of file ClearDisassemblyHighlightCmd.cc.

74  {
75  return "clear_console.png";
76 }

◆ id()

int ClearDisassemblyHighlightCmd::id ( ) const
virtual

Returns ID of this command.

Implements GUICommand.

Definition at line 83 of file ClearDisassemblyHighlightCmd.cc.

References ProximConstants::COMMAND_CLEAR_DISASSEMBLY_HIGHLIGHT.

◆ isEnabled()

bool ClearDisassemblyHighlightCmd::isEnabled ( )
virtual

Returns true if the command is enabled, false otherwise.

Returns
True if the console window exists.

Implements GUICommand.

Definition at line 105 of file ClearDisassemblyHighlightCmd.cc.

105  {
106  if (ProximToolbox::frontend()->isProgramLoaded()) {
107  return true;
108  } else {
109  return false;
110  }
111 }

References ProximToolbox::frontend().

Here is the call graph for this function:

The documentation for this class was generated from the following files:
ProximToolbox::frontend
static TracedSimulatorFrontend * frontend()
Definition: ProximToolbox.cc:223
ProximConstants::COMMAND_CLEAR_DISASSEMBLY_HIGHLIGHT
@ COMMAND_CLEAR_DISASSEMBLY_HIGHLIGHT
Definition: ProximConstants.hh:74
ProximDisassemblyWindow::setMoveAttrProvider
void setMoveAttrProvider(ProximDisasmAttrProvider *attrProvider)
Definition: ProximDisassemblyWindow.cc:391
assert
#define assert(condition)
Definition: Application.hh:86
GUICommand::GUICommand
GUICommand(std::string name, wxWindow *parent)
Definition: GUICommand.cc:42
ClearDisassemblyHighlightCmd::ClearDisassemblyHighlightCmd
ClearDisassemblyHighlightCmd()
Definition: ClearDisassemblyHighlightCmd.cc:43
ProximToolbox::disassemblyWindow
static ProximDisassemblyWindow * disassemblyWindow()
Definition: ProximToolbox.cc:150
ProximDisassemblyWindow
Definition: ProximDisassemblyWindow.hh:58