Gets informed about changes to a component's hierarchy or position.
To monitor a component for changes, register a subclass of ComponentListener with the component using Component::addComponentListener().
Be sure to deregister listeners before you delete them!
- See also
- Component::addComponentListener, Component::removeComponentListener
The documentation for this class was generated from the following file:
◆ ~ComponentListener()
| virtual juce::ComponentListener::~ComponentListener |
( |
| ) |
|
|
virtualdefault |
◆ componentMovedOrResized()
| virtual void juce::ComponentListener::componentMovedOrResized |
( |
Component & | component, |
|
|
bool | wasMoved, |
|
|
bool | wasResized ) |
|
virtual |
◆ componentBroughtToFront()
| virtual void juce::ComponentListener::componentBroughtToFront |
( |
Component & | component | ) |
|
|
virtual |
◆ componentVisibilityChanged()
| virtual void juce::ComponentListener::componentVisibilityChanged |
( |
Component & | component | ) |
|
|
virtual |
◆ componentChildrenChanged()
| virtual void juce::ComponentListener::componentChildrenChanged |
( |
Component & | component | ) |
|
|
virtual |
◆ componentParentHierarchyChanged()
| virtual void juce::ComponentListener::componentParentHierarchyChanged |
( |
Component & | component | ) |
|
|
virtual |
◆ componentNameChanged()
| virtual void juce::ComponentListener::componentNameChanged |
( |
Component & | component | ) |
|
|
virtual |
◆ componentBeingDeleted()
| virtual void juce::ComponentListener::componentBeingDeleted |
( |
Component & | component | ) |
|
|
virtual |
Called when the component is in the process of being deleted.
This callback is made from inside the destructor, so be very, very cautious about what you do in here.
In particular, bear in mind that it's the Component base class's destructor that calls this - so if the object that's being deleted is a subclass of Component, then the subclass layers of the object will already have been destructed when it gets to this point!
- Parameters
-
| component | the component that was deleted |
Reimplemented in juce::ComponentMovementWatcher, and juce::RelativeCoordinatePositionerBase.
◆ componentEnablementChanged()
| virtual void juce::ComponentListener::componentEnablementChanged |
( |
Component & | component | ) |
|
|
virtual |
◆ componentPainted()
Called each time the component is painted into a context.
This will be called once, each time the component is painted into a graphics context. This might be to paint the component directly or to paint a cached image of the component. To get more detailed information regarding user overridable paint methods see componentPaintMethodsCalled().
This callback may be called while trying to paint components. This means the time taken in this callback may be taken into account as part of any parent components ComponentPaintDiagnostics. Therefore, an effort should be made to keep any work in this callback to a bare minimum in order to prevent distorting any results.
It's important not to rely on the precise timing of this callback. The only guarantees are that the callback will occur some time after the component is painted (although the contents of that paint call may not have been updated to the screen).
- Parameters
-
| component | the component that was painted |
| diagnostics | general diagnostics for painting the component |
- See also
- componentPaintMethodsCalled