Lines 11-22
Link Here
|
11 |
*******************************************************************************/ |
11 |
*******************************************************************************/ |
12 |
package org.eclipse.jst.pagedesigner.itemcreation.customizer; |
12 |
package org.eclipse.jst.pagedesigner.itemcreation.customizer; |
13 |
|
13 |
|
|
|
14 |
import org.eclipse.core.resources.IFile; |
14 |
import org.eclipse.core.runtime.IAdaptable; |
15 |
import org.eclipse.core.runtime.IAdaptable; |
15 |
import org.eclipse.core.runtime.IStatus; |
16 |
import org.eclipse.core.runtime.IStatus; |
|
|
17 |
import org.eclipse.jst.pagedesigner.dom.IDOMPosition; |
16 |
|
18 |
|
17 |
/** |
19 |
/** |
18 |
* Interface used to declare an object that customizes tag creation data prior |
20 |
* Interface used to declare an object that customizes tag creation data prior |
19 |
* to a drop. The drop customizer should be used to illicit data on per-drop basis. |
21 |
* to a drop. The drop customizer should be used to ellicit data on per-drop basis. |
20 |
* |
22 |
* |
21 |
* Clients should not implement this interface. Extend AbstractDropCustomizer instead. |
23 |
* Clients should not implement this interface. Extend AbstractDropCustomizer instead. |
22 |
* |
24 |
* |
Lines 27-32
Link Here
|
27 |
public interface IDropCustomizer |
29 |
public interface IDropCustomizer |
28 |
{ |
30 |
{ |
29 |
/** |
31 |
/** |
|
|
32 |
* This is deprecated and is no longer called directly. AbstractDropCustomizer |
33 |
* will call this from runCustomizer(IFile) in the default case. |
34 |
* |
35 |
* @return the status condition of the customizer |
36 |
* @deprecated |
37 |
*/ |
38 |
public IStatus runCustomizer(); |
39 |
|
40 |
/** |
30 |
* Executed when the user performs a drop gesture for a tag, but before the |
41 |
* Executed when the user performs a drop gesture for a tag, but before the |
31 |
* command is dispatched to create the tag in the target document. Implementers |
42 |
* command is dispatched to create the tag in the target document. Implementers |
32 |
* may do calculations or raise customization UI. There return value is used |
43 |
* may do calculations or raise customization UI. There return value is used |
Lines 39-48
Link Here
|
39 |
* NOTE: This method may be called on the UI thread, although this is not guaranteed. |
50 |
* NOTE: This method may be called on the UI thread, although this is not guaranteed. |
40 |
* Implementer should ensure that anything that is long-running (such as a dialog) |
51 |
* Implementer should ensure that anything that is long-running (such as a dialog) |
41 |
* is user-cancellable and that any UI code is run on the display thread. |
52 |
* is user-cancellable and that any UI code is run on the display thread. |
|
|
53 |
* @param file |
54 |
* @param position the position in the target file where the new tag will be dropped |
42 |
* |
55 |
* |
43 |
* @return the status condition of the customizer |
56 |
* @return the status condition of the customizer |
44 |
*/ |
57 |
*/ |
45 |
public IStatus runCustomizer(); |
58 |
|
|
|
59 |
public IStatus runCustomizer(final IFile file, final IDOMPosition position); |
46 |
|
60 |
|
47 |
/** |
61 |
/** |
48 |
* @return the customization data. This method will only be called after runCustomizer |
62 |
* @return the customization data. This method will only be called after runCustomizer |