Sourceforge.net - The VCF's Project Host
   The VCF Website Home   |   Online Discussion Forums   |   Sourceforge.net Project Page   

VCF::PopupMenu Class Reference

This class is for creating popup menus, sometimes referred to as a context, or contextual menu. More...

#include <vcf/ApplicationKit/PopupMenu.h>

Inheritance diagram for VCF::PopupMenu:

VCF::Menu VCF::UIComponent VCF::Component VCF::ObjectWithCallbacks VCF::Object List of all members.

Public Member Functions

 PopupMenu (Control *control=NULL)
 PopupMenu (Component *owner)
 PopupMenu (const String &name, Component *owner)
 PopupMenu (const String &name)
virtual ~PopupMenu ()
virtual MenuItempopup (Point *pt)
 This "pops up" a context menu and shows it to the user.
void setControl (Control *control)

Protected Member Functions

void init ()
virtual void destroy ()
 called by the free() method.

Protected Attributes

PopupMenuPeerpopupPeer_

Detailed Description

This class is for creating popup menus, sometimes referred to as a context, or contextual menu.

Generally it used when the user right clicks on a control.


Constructor & Destructor Documentation

VCF::PopupMenu::PopupMenu Control control = NULL  ) 
 

VCF::PopupMenu::PopupMenu Component owner  ) 
 

VCF::PopupMenu::PopupMenu const String name,
Component owner
 

VCF::PopupMenu::PopupMenu const String name  ) 
 

virtual VCF::PopupMenu::~PopupMenu  )  [virtual]
 


Member Function Documentation

virtual void VCF::PopupMenu::destroy  )  [protected, virtual]
 

called by the free() method.

Should be overriden and any clean up code performed here

Reimplemented from VCF::Menu.

void VCF::PopupMenu::init  )  [protected]
 

virtual MenuItem* VCF::PopupMenu::popup Point pt  )  [virtual]
 

This "pops up" a context menu and shows it to the user.

If the user clicks on a menu item in the popup menu, that menu item is returned. Keep in mind that the menu item is "owned" by the popup menu instance, and is destroyed when the popup menu is.

Returns:
MenuItem returns a pointer to the menu item that the user selected, or NULL if the user dismissed the popup menu without clicking on any menu item.

void VCF::PopupMenu::setControl Control control  ) 
 


Member Data Documentation

PopupMenuPeer* VCF::PopupMenu::popupPeer_ [protected]
 


The documentation for this class was generated from the following file:
   Comments or Suggestions?    License Information