EtsT_Obj_Model_Menu_Click_Handler

Abstract

Callback: Used to specify a custom menu for an application’s response when a user right-clicks an object.

Syntax

<model_menu_click_handler_name> (obj_handle, menu_item_list_ptr)
Argument Type Description
obj_handle EtsT_Obj_Handle Handle to the object that was clicked.
menu_item_list_ptr PrgT_List * List of menu items to be displayed.

Return Type

EtsT_Obj_Click_Return

One of the following constants:

EtsC_Obj_Click_Continue— indicates that the application should continue handling the click by displaying the menu.

EtsC_Obj_Click_Handled— indicates that the click has been handled and the application should not do any further processing.

ets_api_obj.h

Details

Model menu click handlers let you make changes to the Object pop-up menu that an application displays when the user right-clicks an object. If a model menu click handler is specified for an object, the application calls it when the user right-clicks that object. The handler is passed the object handle and a list of strings comprising the menu that the application intends to display to the user.

The model menu click handler can alter the menu contents or perform other processing. If the handler returns EtsC_Obj_Click_Continue, the application displays the menu and lets the user choose an item from it. In addition, if a model menu choose handler is specified, the application calls that function if the user makes a selection from the menu.

If the model menu click handler returns EtsC_Obj_Click_Handled, the right-click event is “consumed” and no menu is shown.

本站文档由 北京智网畅联科技有限公司 整理、翻译并提供 · Documentation compiled and provided by Beijing ZNetLink Technology Co., Ltd.

交流群 · QQ Group:OPNET/智网妙算网络仿真交流群(群号 486383494)

原文档 © 2017 Riverbed Technology · 本站为公益翻译,由 AI 辅助完成,请仔细甄别

Original documentation © 2017 Riverbed Technology. Community translation, AI-assisted. Contact: jiazequn@znetlink.com