JUCE: PopupMenu::CustomCallback Class Reference

JUCE

Public Member Functions | List of all members
PopupMenu::CustomCallback Class Referenceabstract
juce_gui_basics » menus

A user-defined callback that can be used for specific items in a popup menu. More...

`#include <juce_PopupMenu.h>`

Inheritance diagram for PopupMenu::CustomCallback:

## Public Member Functions
| CustomCallback ()
| ~CustomCallback () override
virtual bool | menuItemTriggered ()=0
| Callback to indicate this item has been triggered. More...
Public Member Functions inherited from SingleThreadedReferenceCountedObject
void | incReferenceCount () noexcept
| Increments the object's reference count. More...
void | decReferenceCount () noexcept
| Decreases the object's reference count. More...
bool | decReferenceCountWithoutDeleting () noexcept
| Decreases the object's reference count. More...
int | getReferenceCount () const noexcept
| Returns the object's current reference count. More...

## Additional Inherited Members
Protected Member Functions inherited from SingleThreadedReferenceCountedObject
| SingleThreadedReferenceCountedObject ()=default
| Creates the reference-counted object (with an initial ref count of zero). More...
| SingleThreadedReferenceCountedObject (const SingleThreadedReferenceCountedObject &)
| Copying from another object does not affect this one's reference-count. More...
| SingleThreadedReferenceCountedObject (SingleThreadedReferenceCountedObject &&)
| Copying from another object does not affect this one's reference-count. More...
SingleThreadedReferenceCountedObject & | operator= (const SingleThreadedReferenceCountedObject &)
| Copying from another object does not affect this one's reference-count. More...
SingleThreadedReferenceCountedObject & | operator= (SingleThreadedReferenceCountedObject &&)
| Copying from another object does not affect this one's reference-count. More...
virtual | ~SingleThreadedReferenceCountedObject ()
| Destructor. More...

## Detailed Description

A user-defined callback that can be used for specific items in a popup menu.

See also
  PopupMenu::Item::customCallback

## Constructor & Destructor Documentation

## ◆ CustomCallback()

PopupMenu::CustomCallback::CustomCallback | ( |  | ) |

## ◆ ~CustomCallback()

PopupMenu::CustomCallback::~CustomCallback | ( |  | ) |
| override

## Member Function Documentation

## ◆ menuItemTriggered()

virtual bool PopupMenu::CustomCallback::menuItemTriggered | ( |  | ) |
| pure virtual

Callback to indicate this item has been triggered.

Returns
  true if the itemID should be sent to the exitModalState method, or false if it should send 0, indicating no further action should be taken

The documentation for this class was generated from the following file:

- juce_PopupMenu.h