CMS 3D CMS Logo

IgQtObjectMenuMessage Class Reference

A message notifying that a context-sensitive menu for an object is about to be popped up or needs to be updated. More...

#include <Iguana/Studio/interface/IgQtObjectMenuMessage.h>

List of all members.

Public Member Functions

 IgQtObjectMenuMessage (IgQtObjectMenu *menu, IgRepresentable *object)
 Construct a new message for a menu and context object.
IgQtObjectMenumenu (void) const
 Return the menu.
IgRepresentableobject (void) const
 Return the context object.

Private Attributes

IgQtObjectMenum_menu
IgRepresentablem_object


Detailed Description

A message notifying that a context-sensitive menu for an object is about to be popped up or needs to be updated.

The message's IgRepresentable points to the object for which menu items should be provided; it will never be null. Observers should always check with the menu()'s IgQtObjectMenu::seen() whether their items are already listed in the menu, as this message can be sent with the items already added, e.g. by a browser to update a torn-off menu for a new selection focus. On the other hand, already added items might have been destroyed since the previous message.

Items on the menu should be updated to appropriate states before returning: enabled, checked and relevant. Newly added items are always relevant but should be updated for the other states. (FIXME: explain relevant vs. enabled policy.) (FIXME: multiple selection?)

Definition at line 35 of file IgQtObjectMenuMessage.h.


Constructor & Destructor Documentation

IgQtObjectMenuMessage::IgQtObjectMenuMessage ( IgQtObjectMenu menu,
IgRepresentable object 
) [inline]

Construct a new message for a menu and context object.

Definition at line 56 of file IgQtObjectMenuMessage.h.

00058     : m_menu (menu),
00059       m_object (object)
00060 {}


Member Function Documentation

IgQtObjectMenu * IgQtObjectMenuMessage::menu ( void   )  const [inline]

Return the menu.

Definition at line 64 of file IgQtObjectMenuMessage.h.

References m_menu.

Referenced by VisEventContentTwigOps::menuAction(), VisG4TwigOps::menuAction(), IgTwigOps::menuAction(), Ig3DBaseBrowser::repMenu(), IgSpareWindow::repMenu(), IgLegoWindow::repMenu(), Ig3DWindow::repMenu(), IgRPhiWindow::repMenu(), and IgRZWindow::repMenu().

00065 { return m_menu; }

IgRepresentable * IgQtObjectMenuMessage::object ( void   )  const [inline]

Return the context object.

Definition at line 69 of file IgQtObjectMenuMessage.h.

References m_object.

Referenced by VisEventContentTwigOps::menuAction(), VisG4TwigOps::menuAction(), IgTwigOps::menuAction(), Ig3DBaseBrowser::repMenu(), IgSpareWindow::repMenu(), IgLegoWindow::repMenu(), Ig3DWindow::repMenu(), IgRPhiWindow::repMenu(), and IgRZWindow::repMenu().

00070 { return m_object; }


Member Data Documentation

IgQtObjectMenu* IgQtObjectMenuMessage::m_menu [private]

Definition at line 47 of file IgQtObjectMenuMessage.h.

Referenced by menu().

IgRepresentable* IgQtObjectMenuMessage::m_object [private]

Definition at line 48 of file IgQtObjectMenuMessage.h.

Referenced by object().


The documentation for this class was generated from the following file:
Generated on Tue Jun 9 18:25:27 2009 for CMSSW by  doxygen 1.5.4