AfrFoundation CATExtIContextualMenu
Usage: you can derive this class.
public class CATExtIContextualMenu
Adapter class of the CATIContextualMenu interface.
Two ways to implement this interface:
- You want to customize a default menu which contains these commands: Cut, Copy, Paste,
PasteSpecial, Delete, Open Properties, Selection Sets, Define Selection Sets , Hide/Show and
some commands about the graph if your window contains one.
So in the constructor of your data extension you
retrieve the default contextual menu, thanks to , and you create several items, that you chain to it. It is not necessary to overwrite the
GetContextualMenu method.
Example of constructor:
MyDataExtensionClass::MyDataExtensionClass
{
CATCmdContainer * pMenu = NULL ;
CATExtIContextualMenu::GetContextualMenu(pMenu);
NewAccess(CATCmdStarter,pst1,"CAAPst1Module");
.....
AddAccessChild(pMenu,pst1);
}
- You want a specific contextual menu.
So you write a data extension in overwriting
to return your own menu. Your extension creates a CATCmdContainer (the menu) and manages completely its content and its destruction.
- See also:
-
Constructor and Destructor Index
- o
CATExtIContextualMenu()
- Default constructor.
- o
~CATExtIContextualMenu()
-
Method Index
- o
GetContextualMenu(CATCmdContainer*&)
- Returns the contextual menu.
Constructor and Destructor
o CATExtIContextualMenu
public CATExtIContextualMenu( | ) |
-
Default constructor.
Note:Initializes the contextual menu with commands defined at the top of
this page.
o ~CATExtIContextualMenu
public ~CATExtIContextualMenu( | ) |
-
Methods
o GetContextualMenu
public virtual GetContextualMenu( | | oMenu) |
-
Returns the contextual menu.
Note:This method returns the contextual menu. Its content can change between
two calls.
This object is included in the file: CATExtIContextualMenu.h
If needed, your Imakefile.mk should include the module: CATAfrFoundation
Copyright © 1999-2015, Dassault Systèmes. All rights reserved.