root / branches / v2_0_0_prep / applications / appgvSIG / src / org / gvsig / app / project / documents / layout / contextmenu / gui / AbstractLayoutContextMenuAction.java @ 29598
History | View | Annotate | Download (1.55 KB)
1 |
package org.gvsig.app.project.documents.layout.contextmenu.gui; |
---|---|
2 |
|
3 |
import java.util.Map; |
4 |
|
5 |
import org.gvsig.app.project.documents.contextMenu.AbstractContextMenuAction; |
6 |
import org.gvsig.app.project.documents.layout.LayoutContext; |
7 |
import org.gvsig.app.project.documents.layout.fframes.IFFrame; |
8 |
import org.gvsig.app.project.documents.layout.gui.Layout; |
9 |
import org.gvsig.tools.extensionpoint.ExtensionBuilder; |
10 |
|
11 |
|
12 |
public abstract class AbstractLayoutContextMenuAction extends |
13 |
AbstractContextMenuAction implements ExtensionBuilder {
|
14 |
private Layout layout;
|
15 |
|
16 |
public Layout getLayout() {
|
17 |
return this.layout; |
18 |
} |
19 |
|
20 |
public void setLayout(Layout layout) { |
21 |
this.layout = layout;
|
22 |
} |
23 |
|
24 |
public boolean isEnabled(LayoutContext layoutContext, IFFrame[] selectedFrames) { |
25 |
return true; |
26 |
} |
27 |
|
28 |
public boolean isVisible(LayoutContext layoutContext, IFFrame[] selectedFrames) { |
29 |
return true; |
30 |
} |
31 |
|
32 |
public abstract void execute(LayoutContext layoutContext, IFFrame[] selectedFrames); |
33 |
|
34 |
public Object create() { |
35 |
return this; |
36 |
} |
37 |
|
38 |
public Object create(Map args) { |
39 |
// TODO Auto-generated method stub
|
40 |
return this; |
41 |
} |
42 |
|
43 |
public Object create(Object[] args) { |
44 |
// TODO Auto-generated method stub
|
45 |
return this; |
46 |
} |
47 |
|
48 |
public boolean isEnabled(Object item, Object[] selectedItems) { |
49 |
return isEnabled((LayoutContext)item,(IFFrame[]) selectedItems); |
50 |
} |
51 |
|
52 |
public boolean isVisible(Object item, Object[] selectedItems) { |
53 |
return isVisible((LayoutContext)item,(IFFrame[]) selectedItems); |
54 |
} |
55 |
|
56 |
public void execute(Object item, Object[] selectedItems) { |
57 |
execute((LayoutContext)item,(IFFrame[]) selectedItems);
|
58 |
|
59 |
} |
60 |
|
61 |
} |