Version: 8.3.0
YACS::HMI::ContainerMenu Class Reference

#include <Menus.hxx>

Inheritance diagram for YACS::HMI::ContainerMenu:
Collaboration diagram for YACS::HMI::ContainerMenu:

Public Member Functions

 ContainerMenu ()
 
virtual ~ContainerMenu ()
 
virtual void popupMenu (QWidget *caller, const QPoint &globalPos, const QString &m="Container Menu")
 
- Public Member Functions inherited from YACS::HMI::MenusBase
 MenusBase ()
 
virtual ~MenusBase ()
 
virtual void addForEachMenu (QMenu *m, QActionGroup *actgroup)
 
virtual void addForEachMenuToPutGraph (QMenu *m, QActionGroup *actgroup)
 

Additional Inherited Members

- Protected Slots inherited from YACS::HMI::MenusBase
void dummyAction ()
 
void foreachAction (QAction *)
 
void putGraphInForeachAction (QAction *)
 
- Protected Member Functions inherited from YACS::HMI::MenusBase
virtual void buildForEachMenu (QMenu *m, QActionGroup *actgroup)
 
virtual void addHeader (QMenu &m, const QString &h)
 
- Protected Attributes inherited from YACS::HMI::MenusBase
QAction * _dummyAct
 

Detailed Description

Definition at line 196 of file Menus.hxx.

Constructor & Destructor Documentation

ContainerMenu::ContainerMenu ( )

Definition at line 643 of file Menus.cxx.

643  : MenusBase()
644 {
645 }
ContainerMenu::~ContainerMenu ( )
virtual

Definition at line 647 of file Menus.cxx.

648 {
649 }

Member Function Documentation

void ContainerMenu::popupMenu ( QWidget caller,
const QPoint &  globalPos,
const QString &  m = "Container Menu" 
)
virtual

Reimplemented from YACS::HMI::MenusBase.

Definition at line 651 of file Menus.cxx.

References YACS::HMI::GenericGui::_deleteItemAct, YACS::HMI::MenusBase::addHeader(), YACS::HMI::QtGuiContext::getGMain(), YACS::HMI::QtGuiContext::getQtCurrent(), and YACS::HMI::QtGuiContext::isEdition().

Referenced by YACS::HMI::SchemaContainerItem::popupMenu().

652 {
654  bool isEdition = QtGuiContext::getQtCurrent()->isEdition();
655  QMenu menu(m, caller);
656  addHeader(menu, m);
657  if (isEdition)
658  {
659  menu.addAction(gmain->_deleteItemAct);
660  }
661  menu.exec(globalPos);
662 }

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