OpenASIP  2.0
Public Member Functions | Private Attributes | List of all members
EditorCommand Class Reference

#include <EditorCommand.hh>

Inherits GUICommand.

Inherited by AboutCmd, AddASCmd, AddBridgeCmd, AddBusCmd, AddFUCmd, AddFUFromHDBCmd, AddGCUCmd, AddIUCmd, AddIUFromHDBCmd, AddRFCmd, AddRFFromHDBCmd, AddSocketCmd, BlocksConnectICCmd, CallExplorerPluginCmd, CloseDocumentCmd, CopyComponentCmd, CutComponentCmd, DeleteComponentCmd, EditAddressSpacesCmd, EditBusOrderCmd, EditConnectionsCmd, EditImmediateSlotsCmd, EditMachineCmd, EditOptionsCmd, EditOTAFormatsCmd, EditTemplatesCmd, FitHeightCmd, FitWidthCmd, FitWindowCmd, FullyConnectBussesCmd, ImplementMachineCmd, ModifyComponentCmd, NewDocumentCmd, OpenDocumentCmd, PasteComponentCmd, PrintCmd, PrintPreviewCmd, ProDeExportCmd, QuitCmd, RedoCmd, SaveDocumentAsCmd, SaveDocumentCmd, SaveOptionsCmd, SelectCmd, ToggleUnitDetailsCmd, UndoCmd, VerifyMachineCmd, VLIWConnectICCmd, ZoomInCmd, and ZoomOutCmd.

Collaboration diagram for EditorCommand:
Collaboration graph

Public Member Functions

 EditorCommand (std::string name, wxWindow *parent=NULL)
 
virtual ~EditorCommand ()
 
void setView (wxView *view)
 
wxView * view () const
 
virtual std::string icon () const
 
virtual bool isEnabled ()
 
- Public Member Functions inherited from GUICommand
 GUICommand (std::string name, wxWindow *parent)
 
virtual ~GUICommand ()
 
virtual int id () const =0
 
virtual GUICommandcreate () const =0
 
virtual bool Do ()=0
 
virtual bool isChecked () const
 
virtual std::string shortName () const
 
void setParentWindow (wxWindow *view)
 
wxWindow * parentWindow () const
 
std::string name () const
 

Private Attributes

wxView * view_
 The view assigned for the command. More...
 

Detailed Description

Base class for editor commands, which can be added to menus or toolbar.

Definition at line 46 of file EditorCommand.hh.

Constructor & Destructor Documentation

◆ EditorCommand()

EditorCommand::EditorCommand ( std::string  name,
wxWindow *  parent = NULL 
)

The Constructor.

Definition at line 42 of file EditorCommand.cc.

42  :
43  GUICommand(name, parent),
44  view_(NULL) {
45 
46 }

◆ ~EditorCommand()

EditorCommand::~EditorCommand ( )
virtual

The Destructor.

Definition at line 53 of file EditorCommand.cc.

53  {
54 }

Member Function Documentation

◆ icon()

string EditorCommand::icon ( ) const
virtual

◆ isEnabled()

bool EditorCommand::isEnabled ( )
virtual

◆ setView()

void EditorCommand::setView ( wxView *  view)

Sets the MDFView of the command.

Parameters
viewMDFView to be assigned for the command.

Definition at line 65 of file EditorCommand.cc.

65  {
66  view_ = view;
67 }

References view(), and view_.

Referenced by MainFrame::onCommandEvent(), SelectTool::onMouseEvent(), and MainFrame::onUpdateUI().

Here is the call graph for this function:

◆ view()

wxView * EditorCommand::view ( ) const

Member Data Documentation

◆ view_

wxView* EditorCommand::view_
private

The view assigned for the command.

Definition at line 58 of file EditorCommand.hh.

Referenced by setView(), and view().


The documentation for this class was generated from the following files:
EditorCommand::view_
wxView * view_
The view assigned for the command.
Definition: EditorCommand.hh:58
GUICommand::name
std::string name() const
Definition: GUICommand.cc:99
EditorCommand::view
wxView * view() const
Definition: EditorCommand.cc:76
ProDeConstants::CMD_ICON_DEFAULT
static const std::string CMD_ICON_DEFAULT
Icon path for default icon of commands.
Definition: ProDeConstants.hh:286
GUICommand::GUICommand
GUICommand(std::string name, wxWindow *parent)
Definition: GUICommand.cc:42