rwlogo
Rogue Wave Views 5.6

Rogue Wave Views
Manager Package API Reference Guide

Product Documentation:

Rogue Wave Views
Documentation Home

IlvManagerViewHook Class Reference

Manager hook class. More...

#include <ilviews/manager/hook.h>

Inheritance diagram for IlvManagerViewHook:
IlvManagerViewInteractorSelector IlvMatrixHook

List of all members.

Public Member Functions

 IlvManagerViewHook (IlvManager *manager=0, IlvView *view=0)
 Constructor.
virtual void afterDraw (IlvPort *dst, const IlvTransformer *t=0, const IlvRegion *region=0, const IlvRegion *clip=0)
 Called after the manager has drawn its contents.
virtual void afterExpose (const IlvRect &rect)
 Called after the manager has received an Expose event in the view to which the hook is connected.
virtual void beforeDraw (IlvPort *dst, const IlvTransformer *t=0, const IlvRegion *region=0, const IlvRegion *clip=0)
 Called before the manager draws its contents.
virtual void contentsChanged ()
 Called when the contents of the manager change.
IlvManagergetManager () const
 Returns the manager.
IlvViewgetView () const
 Returns the manager view.
virtual void interactorChanged (IlvManagerViewInteractor *current, IlvManagerViewInteractor *previous)
 Called when the interactor of the manager view changes.
void setManager (IlvManager *manager)
 Sets the manager.
void setView (IlvView *view)
 Sets the manager view.
virtual void transformerChanged (const IlvTransformer *current, const IlvTransformer *previous)
 Called when you change the transformer of the view to which the hook is connected.
virtual void viewRemoved ()
 Called when the view to which the hook is connected is removed from the list of views that the manager handles.
virtual void viewResized ()
 Called when the manager view is resized.

Friends

class IlvMgrView

Detailed Description

Manager hook class.

Library: ilvmgr

There is a mechanism that lets you detect events such as drawing in a view, changing a transformer, and so on. This mechanism is implemented by using view hooks. A view hook is an instance of the IlvManagerViewHook class. This class has a number of virtual member functions that are automatically called by Rogue Wave Views when particular operations occur in a manager.

See also:
IlvManager::installViewHook, IlvManager::removeViewHook, IlvMatrixHook.

Constructor & Destructor Documentation

IlvManagerViewHook::IlvManagerViewHook ( IlvManager manager = 0,
IlvView view = 0 
)

Constructor.

The constructor initializes a new view hook.

Parameters:
manager Specifies the manager.
view The view on which to detect events. The view must be connected to manager.

Member Function Documentation

virtual void IlvManagerViewHook::afterDraw ( IlvPort dst,
const IlvTransformer t = 0,
const IlvRegion region = 0,
const IlvRegion clip = 0 
) [virtual]

Called after the manager has drawn its contents.

Acts the same way as IlvManagerViewHook::beforeDraw but is called after the manager has updated the view. This lets you create additional drawings on top of those drawn by the manager.

virtual void IlvManagerViewHook::afterExpose ( const IlvRect rect  )  [virtual]

Called after the manager has received an Expose event in the view to which the hook is connected.

Parameters:
rect The rectangular area exposed.
virtual void IlvManagerViewHook::beforeDraw ( IlvPort dst,
const IlvTransformer t = 0,
const IlvRegion region = 0,
const IlvRegion clip = 0 
) [virtual]

Called before the manager draws its contents.

Called internally by the manager to which this hook is connected, just before it redraws the hook view. Use this function if you need to perform additional drawings in the view before the manager draws it.

Parameters:
dst The output port for the drawing functions. It can be different from the view itself.
t The transformer applied by the manager to the view.
region Contains the areas to be refreshed (in the view coordinate system).
clip The clipping region to be used.
IlvManager* IlvManagerViewHook::getManager (  )  const

Returns the manager.

Returns:
The manager for which this hook was created.
IlvView* IlvManagerViewHook::getView (  )  const

Returns the manager view.

Returns:
The view this hook acts on.
virtual void IlvManagerViewHook::interactorChanged ( IlvManagerViewInteractor current,
IlvManagerViewInteractor previous 
) [virtual]

Called when the interactor of the manager view changes.

Called when you change the view interactor for the view to which the hook is connected.

Parameters:
current The new interactor set on the view.
previous The interactor previously set on the view.

Reimplemented in IlvMatrixHook, and IlvManagerViewInteractorSelector.

void IlvManagerViewHook::setManager ( IlvManager manager  ) 

Sets the manager.

Connects the hook to a manager. This lets you use the same hook in several managers, one after the other. Use the member function IlvManagerViewHook::setView to modify the view you want this hook to act on.

Parameters:
manager The manager to connect to.
void IlvManagerViewHook::setView ( IlvView view  ) 

Sets the manager view.

Sets the view on which to watch events. This lets you use the same hook in several views in the same manager, one after the other.

Parameters:
view Specifies the view. It must be connected to the manager.
virtual void IlvManagerViewHook::transformerChanged ( const IlvTransformer current,
const IlvTransformer previous 
) [virtual]

Called when you change the transformer of the view to which the hook is connected.

Parameters:
current The new transformer set on the view.
previous The transformer previously set on the view.
virtual void IlvManagerViewHook::viewResized (  )  [virtual]

Called when the manager view is resized.

Called when the view to which the hook is connected is resized.

 All Classes Files Functions Variables Typedefs Enumerations Enumerator Friends Defines

© Copyright 2012, 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.