LibreOffice
LibreOffice 6.2 SDK API Reference
Public Member Functions | List of all members
XExtendedToolkit Interface Referencepublished

The XExtendedToolkit is an extension of the com::sun::star::awt::XToolkit interface. More...

import"XExtendedToolkit.idl";

Inheritance diagram for XExtendedToolkit:
XInterface XToolkit2 Toolkit XToolkitExperimental

Public Member Functions

long getTopWindowCount ()
 This function returns the number of currently existing top-level windows. More...
 
::com::sun::star::awt::XTopWindow getTopWindow ([in] long nIndex) raises (::com::sun::star::lang::IndexOutOfBoundsException)
 Return a reference to the specified top-level window. More...
 
::com::sun::star::awt::XTopWindow getActiveTopWindow ()
 Return the currently active top-level window, i.e. More...
 
void addTopWindowListener ([in]::com::sun::star::awt::XTopWindowListener xListener)
 Add a new listener that is called for events that involve com::sun::star::awt::XTopWindow. More...
 
void removeTopWindowListener ([in]::com::sun::star::awt::XTopWindowListener xListener)
 Remove the specified listener from the list of listeners. More...
 
void addKeyHandler ([in]::com::sun::star::awt::XKeyHandler xHandler)
 Add a new listener that is called on com::sun::star::awt::KeyEvent. More...
 
void removeKeyHandler ([in]::com::sun::star::awt::XKeyHandler xHandler)
 Remove the specified listener from the list of listeners. More...
 
void addFocusListener ([in]::com::sun::star::awt::XFocusListener xListener)
 Add a new listener that is called on com::sun::star::awt::FocusEvent. More...
 
void removeFocusListener ([in]::com::sun::star::awt::XFocusListener xListener)
 Remove the specified listener from the list of listeners. More...
 
void fireFocusGained ([in]::com::sun::star::uno::XInterface source)
 Broadcasts the a focusGained on all registered focus listeners. More...
 
void fireFocusLost ([in]::com::sun::star::uno::XInterface source)
 Broadcasts the a focusGained on all registered focus listeners. More...
 
- Public Member Functions inherited from XInterface
any queryInterface ([in] type aType)
 queries for a new interface to an existing UNO object. More...
 
void acquire ()
 increases the reference counter by one. More...
 
void release ()
 decreases the reference counter by one. More...
 

Detailed Description

The XExtendedToolkit is an extension of the com::sun::star::awt::XToolkit interface.

It basically provides access to three event broadcasters which are used for instance in the context of accessibility. It is, however, not restricted to accessibility.

The first event broadcaster lets you keep track of the open top-level windows (frames). To get the set of currently open top-level window use the XExtendedToolkit::getTopWindowCount() and XExtendedToolkit::getTopWindow() methods.

The second event broadcaster informs its listeners of key events. Its listeners can, unlike with most other broadcasters/listeners, consume events, so that other listeners will not be called for consumed events.

The last event broadcaster sends events on focus changes of all elements that can have the input focus.

Deprecated:
This interface was only implemented in an intermediate developer release anyway.
Since
OOo 1.1.2

Member Function Documentation

void addFocusListener ( [in] ::com::sun::star::awt::XFocusListener  xListener)

Add a new listener that is called on com::sun::star::awt::FocusEvent.

Use this focus broadcaster to keep track of the object that currently has the input focus.

Parameters
xListenerIf this is a valid reference it is inserted into the list of listeners. It is the task of the caller to not register the same listener twice (otherwise that listener will be called twice.)
void addKeyHandler ( [in] ::com::sun::star::awt::XKeyHandler  xHandler)

Add a new listener that is called on com::sun::star::awt::KeyEvent.

Every listener is given the opportunity to consume the event, i.e. prevent the not yet called listeners from being called.

Parameters
xHandlerIf this is a valid reference it is inserted into the list of handlers. It is the task of the caller to not register the same handler twice (otherwise that listener will be called twice.)
void addTopWindowListener ( [in] ::com::sun::star::awt::XTopWindowListener  xListener)

Add a new listener that is called for events that involve com::sun::star::awt::XTopWindow.

After having obtained the current list of existing top-level windows you can keep this list up-to-date by listening to opened or closed top-level windows. Wait for activations or deactivations of top-level windows to keep track of the currently active frame.

Parameters
xListenerIf this is a valid reference it is inserted into the list of listeners. It is the task of the caller to not register the same listener twice (otherwise that listener will be called twice.)
void fireFocusGained ( [in] ::com::sun::star::uno::XInterface  source)

Broadcasts the a focusGained on all registered focus listeners.

Parameters
sourceThe object that has gained the input focus. It should implement com::sun::star::accessibility::XAccessible.
void fireFocusLost ( [in] ::com::sun::star::uno::XInterface  source)

Broadcasts the a focusGained on all registered focus listeners.

Parameters
sourceThe object that has lost the input focus. It should implement com::sun::star::accessibility::XAccessible.
::com::sun::star::awt::XTopWindow getActiveTopWindow ( )

Return the currently active top-level window, i.e.

which has currently the input focus.

Returns
The returned reference may be empty when no top-level window is active.
::com::sun::star::awt::XTopWindow getTopWindow ( [in] long  nIndex)
raises (::com::sun::star::lang::IndexOutOfBoundsException
)

Return a reference to the specified top-level window.

Note that the number of top-level windows may change between a call to getTopWindowCount() and successive calls to this function.

Parameters
nIndexThe index should be in the interval from 0 up to but not including the number of top-level windows as returned by getTopWindowCount().
Returns
The returned value is a valid reference to a top-level window.
Exceptions
IndexOutOfBoundsExceptionwhen the specified index is outside the valid range.
long getTopWindowCount ( )

This function returns the number of currently existing top-level windows.

Returns
Returns the number of top-level windows. This includes all top-level windows, regardless of whether they are iconized, visible, or active.
void removeFocusListener ( [in] ::com::sun::star::awt::XFocusListener  xListener)

Remove the specified listener from the list of listeners.

Parameters
xListenerIf the reference is empty then nothing will be changed. If the listener has been registered twice (or more) then all references will be removed.
void removeKeyHandler ( [in] ::com::sun::star::awt::XKeyHandler  xHandler)

Remove the specified listener from the list of listeners.

Parameters
xHandlerIf the reference is empty then nothing will be changed. If the handler has been registered twice (or more) then all references will be removed.
void removeTopWindowListener ( [in] ::com::sun::star::awt::XTopWindowListener  xListener)

Remove the specified listener from the list of listeners.

Parameters
xListenerIf the reference is empty then nothing will be changed. If the listener has been registered twice (or more) then all references will be removed.

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