Rogue Wave Views
Data Access Package API Reference Guide
Product Documentation:

Rogue Wave Views
Documentation Home
List of all members | Public Member Functions
IliDbTreePopupMenuModel Class Reference

Model class. More...

#include <ilviews/dataccess/gadgets/dbtree.h>

Inheritance diagram for IliDbTreePopupMenuModel:
IliModel

Public Member Functions

 IliDbTreePopupMenuModel ()
 The default constructor.
 
void addDeletePopupItem (const char *label=0) const
 Adds the popup menu item to delete the selected item. More...
 
void addEditPopupItem (const char *label=0) const
 Adds the popup menu item to edit the selected item. More...
 
void addInsertChildPopupItem (const char *label=0) const
 Adds the popup menu item to insert a child. More...
 
void addInsertSiblingPopupItem (const char *label=0) const
 Adds the popup menu item to insert a sibling. More...
 
void addPopupItem (const char *label, IlvGraphicCallback cb, IlAny arg=0) const
 Adds a popup menu item. More...
 
void addPopupSeparator () const
 Adds a popup menu item separator.
 
IliDbTreeGadgetgetDbTreeGadget () const
 Returns the IliDbTreeGadget object which uses the model. More...
 
IlBoolean isItemDeletionEnabled () const
 Returns IlTrue if the selected item can be deleted. More...
 
IlBoolean isItemEditionEnabled () const
 Returns IlTrue if the selected item can be edited. More...
 
IlBoolean isItemInsertionChildEnabled () const
 Returns IlTrue if the insertion of a child is possible. More...
 
IlBoolean isItemInsertionSiblingEnabled () const
 Returns IlTrue if the insertion of a sibling is possible. More...
 
virtual void makePopupMenu (IlvDisplay *display) const
 Called to creates the popup menu items of the popup menu. More...
 
- Public Member Functions inherited from IliModel
 IliModel ()
 The constructor initializes a new IliModel instance.
 
IlInt declareProperty (const IliDatatype *typ, const char *name, const char *title, IlBoolean pub)
 Declares a new property. More...
 
virtual void defineProperties ()
 Called to define the list of properties. More...
 
virtual const char * getLabel () const =0
 Returns the model label, it is used by the gadget inspector. More...
 
virtual const char * getMappingInspectorModelName () const
 Returns the mapping inspector model name. More...
 
virtual const char * getName () const
 Returns the model name. More...
 
IlInt getPropertyCount () const
 Returns the property count. More...
 
IlInt getPropertyIndex (const char *name) const
 Returns a property index. More...
 
const char * getPropertyName (IlInt index) const
 Returns a property name. More...
 
const IliValuegetPropertyValue (const char *name) const
 Returns a property value. More...
 
const IliValuegetPropertyValue (IlInt index) const
 Returns a property value. More...
 
virtual IlBoolean isPublic () const
 Returns the model visibility. More...
 
void setPropertyValue (const char *name, const IliValue &val)
 Sets a property value. More...
 
void setPropertyValue (IlInt index, const IliValue &val)
 Sets a property value. More...
 

Detailed Description

Model class.

Library: dbgadget

This class of model is used by the IliDbTreeGadget to display a popup menu. This dialog is used to edit or to create a tree item. If you want to change the popup menu, you must create a sub-class of this class and register it (see macro IliRegisterDbTreePopupMenuModel ). After you can use the setPopupMenuModelName function to specify your popup menu model to your IliDbTreeGadget object.

See also
IliModel, IliDbTreeGadget.

Member Function Documentation

void IliDbTreePopupMenuModel::addDeletePopupItem ( const char *  label = 0) const

Adds the popup menu item to delete the selected item.

Parameters
labelThe popup menu item label. If it is NULL, the default label is used.
void IliDbTreePopupMenuModel::addEditPopupItem ( const char *  label = 0) const

Adds the popup menu item to edit the selected item.

Parameters
labelThe popup menu item label. If it is NULL, the default label is used.
void IliDbTreePopupMenuModel::addInsertChildPopupItem ( const char *  label = 0) const

Adds the popup menu item to insert a child.

Parameters
labelThe popup menu item label. If it is NULL, the default label is used.
void IliDbTreePopupMenuModel::addInsertSiblingPopupItem ( const char *  label = 0) const

Adds the popup menu item to insert a sibling.

Parameters
labelThe popup menu item label. If it is NULL, the default label is used.
void IliDbTreePopupMenuModel::addPopupItem ( const char *  label,
IlvGraphicCallback  cb,
IlAny  arg = 0 
) const

Adds a popup menu item.

Parameters
labelThe label.
cbThe callback which is called when the popup menu item is chosen.
argThe user data.
IliDbTreeGadget* IliDbTreePopupMenuModel::getDbTreeGadget ( ) const

Returns the IliDbTreeGadget object which uses the model.

Returns
The IliDbTreeGadget object.
IlBoolean IliDbTreePopupMenuModel::isItemDeletionEnabled ( ) const

Returns IlTrue if the selected item can be deleted.

Returns
IlTrue if the selected item can be deleted.
IlBoolean IliDbTreePopupMenuModel::isItemEditionEnabled ( ) const

Returns IlTrue if the selected item can be edited.

Returns
IlTrue if the selected item can be edited.
IlBoolean IliDbTreePopupMenuModel::isItemInsertionChildEnabled ( ) const

Returns IlTrue if the insertion of a child is possible.

Returns
IlTrue if the insertion of a child is possible.
IlBoolean IliDbTreePopupMenuModel::isItemInsertionSiblingEnabled ( ) const

Returns IlTrue if the insertion of a sibling is possible.

Returns
IlTrue if the insertion of a sibling is possible.
virtual void IliDbTreePopupMenuModel::makePopupMenu ( IlvDisplay display) const
virtual

Called to creates the popup menu items of the popup menu.

To create the popup menu, you should use the add....PopupItem functions.

Parameters
displayThe display.

© Copyright 2016, Rogue Wave Software, Inc. All Rights Reserved.
Rogue Wave is a registered trademark of Rogue Wave Software, Inc. in the United States and other countries. All other trademarks are the property of their respective owners.