Page 1 of 1
Bootstrap
Posted: Tue Jul 28, 2009 10:39 pm
by dylan
I am looking for a way to register an AuthorListener with AuthorAccess as soon as the application has started.
Is this possible in 10.3?
Thanks,
Dylan.
Re: Bootstrap
Posted: Wed Jul 29, 2009 8:37 am
by Radu
Hi Dylan,
The AuthorAccess is only connected to the current authored file.
So for each authored file there is an AuthorAccess associated with it.
When editing a document type in the Oxygen
Preferences->Document Type Association page in the "Extensions" tab you can set up an
ro.sync.ecss.extensions.api.ExtensionsBundle implementation.
In the implementation you can overwrite the method:
Code: Select all
public AuthorExtensionStateListener createAuthorExtensionStateListener() {
return null;
}
and you will get notified when the current editor gets activated and deactivated (its tab is brought to top or unselected).
When the
void activated(AuthorAccess authorAccess); method is called you can register your listener on the
AuthorAccess.getEditorAccess(). When the page gets de-activated you will remove the listener.
Regards,
Radu