public class MacroWizard extends Object implements WizardListener
| Modifier and Type | Field and Description |
|---|---|
static Command |
INSERT
Rich text area command for inserting a macro in place of the current selection.
|
| Constructor and Description |
|---|
MacroWizard(MacroDisplayer displayer,
Config config,
MacroServiceAsync macroService)
Creates a new macro wizard.
|
| Modifier and Type | Method and Description |
|---|---|
void |
destroy()
Destroy this wizard.
|
void |
edit()
Casts the edit macro spell on the underlying rich text area, allowing the user to edit the parameters
and the content of the currently selected macro.
|
void |
insert()
Casts the insert macro spell on the underlying rich text area, allowing the user to insert a new macro
in place of the current selection or at the current caret position.
|
void |
insert(String macroId)
Casts the insert macro spell on the underlying rich text area, allowing the user to insert the specified
macro in place of the current selection or at the current caret position.
|
void |
onCancel(Wizard sender) |
void |
onFinish(Wizard sender,
Object result) |
public static final Command INSERT
public MacroWizard(MacroDisplayer displayer, Config config, MacroServiceAsync macroService)
displayer - the object used to get information about the displayed macros and to access the rich text area
on which the spells are castconfig - the object used to configure this wizardmacroService - the macro service used to retrieve macro descriptorspublic void edit()
public void insert()
public void insert(String macroId)
macroId - a macro identifierpublic void onCancel(Wizard sender)
onCancel in interface WizardListenerWizardListener.onCancel(Wizard)public void onFinish(Wizard sender, Object result)
onFinish in interface WizardListenerWizardListener.onFinish(Wizard, Object)public void destroy()
Copyright © 2004–2015 XWiki. All rights reserved.