|
|
@ -6,7 +6,10 @@ import com.fr.design.DesignState; |
|
|
|
import com.fr.design.designer.TargetComponent; |
|
|
|
import com.fr.design.designer.TargetComponent; |
|
|
|
import com.fr.design.designer.beans.AdapterBus; |
|
|
|
import com.fr.design.designer.beans.AdapterBus; |
|
|
|
import com.fr.design.designer.beans.Painter; |
|
|
|
import com.fr.design.designer.beans.Painter; |
|
|
|
|
|
|
|
import com.fr.design.designer.beans.actions.CopyAction; |
|
|
|
|
|
|
|
import com.fr.design.designer.beans.actions.CutAction; |
|
|
|
import com.fr.design.designer.beans.actions.FormDeleteAction; |
|
|
|
import com.fr.design.designer.beans.actions.FormDeleteAction; |
|
|
|
|
|
|
|
import com.fr.design.designer.beans.actions.PasteAction; |
|
|
|
import com.fr.design.designer.beans.adapters.layout.FRParameterLayoutAdapter; |
|
|
|
import com.fr.design.designer.beans.adapters.layout.FRParameterLayoutAdapter; |
|
|
|
import com.fr.design.designer.beans.events.CreatorEventListenerTable; |
|
|
|
import com.fr.design.designer.beans.events.CreatorEventListenerTable; |
|
|
|
import com.fr.design.designer.beans.events.DesignerEditListener; |
|
|
|
import com.fr.design.designer.beans.events.DesignerEditListener; |
|
|
@ -43,7 +46,6 @@ import com.fr.form.ui.container.WFitLayout; |
|
|
|
import com.fr.general.ComparatorUtils; |
|
|
|
import com.fr.general.ComparatorUtils; |
|
|
|
import com.fr.general.FRLogger; |
|
|
|
import com.fr.general.FRLogger; |
|
|
|
import com.fr.general.Inter; |
|
|
|
import com.fr.general.Inter; |
|
|
|
import com.fr.plugin.ExtraClassManager; |
|
|
|
|
|
|
|
import com.fr.stable.ArrayUtils; |
|
|
|
import com.fr.stable.ArrayUtils; |
|
|
|
import com.fr.stable.bridge.StableFactory; |
|
|
|
import com.fr.stable.bridge.StableFactory; |
|
|
|
|
|
|
|
|
|
|
@ -69,7 +71,6 @@ public class FormDesigner extends TargetComponent<Form> implements TreeSelection |
|
|
|
protected static final ArrayList<String> NAME_ARRAY_LIST = new ArrayList<String>( |
|
|
|
protected static final ArrayList<String> NAME_ARRAY_LIST = new ArrayList<String>( |
|
|
|
Arrays.asList(new String[]{Inter.getLocText("M_Edit-Cut"), Inter.getLocText("M_Edit-Copy"), Inter.getLocText("M_Edit-Delete")}) |
|
|
|
Arrays.asList(new String[]{Inter.getLocText("M_Edit-Cut"), Inter.getLocText("M_Edit-Copy"), Inter.getLocText("M_Edit-Delete")}) |
|
|
|
); |
|
|
|
); |
|
|
|
private static final int BORDER_WIDTH = 6; |
|
|
|
|
|
|
|
//底层容器的默认大小
|
|
|
|
//底层容器的默认大小
|
|
|
|
protected static final Dimension LARGE_PREFERRED_SIZE = new Dimension(WBorderLayout.DEFAULT_WIDTH, WBorderLayout.DEFAULT_HEIGHT); |
|
|
|
protected static final Dimension LARGE_PREFERRED_SIZE = new Dimension(WBorderLayout.DEFAULT_WIDTH, WBorderLayout.DEFAULT_HEIGHT); |
|
|
|
private int paraHeight = 0; |
|
|
|
private int paraHeight = 0; |
|
|
@ -81,7 +82,7 @@ public class FormDesigner extends TargetComponent<Form> implements TreeSelection |
|
|
|
private XLayoutContainer paraComponent; |
|
|
|
private XLayoutContainer paraComponent; |
|
|
|
private boolean drawLineMode; |
|
|
|
private boolean drawLineMode; |
|
|
|
private FormArea formArea; |
|
|
|
private FormArea formArea; |
|
|
|
private ConnectorHelper ConnectorHelper; |
|
|
|
private ConnectorHelper connectorHelper; |
|
|
|
private boolean isReportBlockEditing = false; |
|
|
|
private boolean isReportBlockEditing = false; |
|
|
|
|
|
|
|
|
|
|
|
//组件重叠
|
|
|
|
//组件重叠
|
|
|
@ -104,7 +105,7 @@ public class FormDesigner extends TargetComponent<Form> implements TreeSelection |
|
|
|
|
|
|
|
|
|
|
|
// 编辑状态的事件表
|
|
|
|
// 编辑状态的事件表
|
|
|
|
private CreatorEventListenerTable edit; |
|
|
|
private CreatorEventListenerTable edit; |
|
|
|
protected Action[] designer_actions; |
|
|
|
protected Action[] designerActions; |
|
|
|
private FormDesignerModeForSpecial<?> desigerMode; |
|
|
|
private FormDesignerModeForSpecial<?> desigerMode; |
|
|
|
private Action switchAction; |
|
|
|
private Action switchAction; |
|
|
|
private FormElementCaseContainerProvider elementCaseContainer; |
|
|
|
private FormElementCaseContainerProvider elementCaseContainer; |
|
|
@ -214,6 +215,7 @@ public class FormDesigner extends TargetComponent<Form> implements TreeSelection |
|
|
|
|
|
|
|
|
|
|
|
/** |
|
|
|
/** |
|
|
|
* 是否有查询按钮 |
|
|
|
* 是否有查询按钮 |
|
|
|
|
|
|
|
* |
|
|
|
* @return 有无查询按钮 |
|
|
|
* @return 有无查询按钮 |
|
|
|
*/ |
|
|
|
*/ |
|
|
|
public boolean isWithQueryButton() { |
|
|
|
public boolean isWithQueryButton() { |
|
|
@ -223,6 +225,7 @@ public class FormDesigner extends TargetComponent<Form> implements TreeSelection |
|
|
|
|
|
|
|
|
|
|
|
/** |
|
|
|
/** |
|
|
|
* 加入参数到参数面板 |
|
|
|
* 加入参数到参数面板 |
|
|
|
|
|
|
|
* |
|
|
|
* @param parameter 参数 |
|
|
|
* @param parameter 参数 |
|
|
|
* @return 是否加入 |
|
|
|
* @return 是否加入 |
|
|
|
*/ |
|
|
|
*/ |
|
|
@ -256,6 +259,7 @@ public class FormDesigner extends TargetComponent<Form> implements TreeSelection |
|
|
|
|
|
|
|
|
|
|
|
/** |
|
|
|
/** |
|
|
|
* 加入参数到参数面板,有查询按钮 |
|
|
|
* 加入参数到参数面板,有查询按钮 |
|
|
|
|
|
|
|
* |
|
|
|
* @param parameter 参数 |
|
|
|
* @param parameter 参数 |
|
|
|
* @return 是否加入 |
|
|
|
* @return 是否加入 |
|
|
|
*/ |
|
|
|
*/ |
|
|
@ -357,6 +361,7 @@ public class FormDesigner extends TargetComponent<Form> implements TreeSelection |
|
|
|
|
|
|
|
|
|
|
|
/** |
|
|
|
/** |
|
|
|
* 自动添加组件 |
|
|
|
* 自动添加组件 |
|
|
|
|
|
|
|
* |
|
|
|
* @param xCreator 组件 |
|
|
|
* @param xCreator 组件 |
|
|
|
* @param x 横坐标 |
|
|
|
* @param x 横坐标 |
|
|
|
* @param y 纵坐标 |
|
|
|
* @param y 纵坐标 |
|
|
@ -375,6 +380,7 @@ public class FormDesigner extends TargetComponent<Form> implements TreeSelection |
|
|
|
|
|
|
|
|
|
|
|
/** |
|
|
|
/** |
|
|
|
* 在参数很多时,全部添加的时候,可以向下一次排版,若去掉就会在参数面板堆到一起 |
|
|
|
* 在参数很多时,全部添加的时候,可以向下一次排版,若去掉就会在参数面板堆到一起 |
|
|
|
|
|
|
|
* |
|
|
|
* @param creator 组件 |
|
|
|
* @param creator 组件 |
|
|
|
* @param x 长度 |
|
|
|
* @param x 长度 |
|
|
|
* @param y 长度 |
|
|
|
* @param y 长度 |
|
|
@ -425,6 +431,7 @@ public class FormDesigner extends TargetComponent<Form> implements TreeSelection |
|
|
|
|
|
|
|
|
|
|
|
/** |
|
|
|
/** |
|
|
|
* 返回根节点父容器 |
|
|
|
* 返回根节点父容器 |
|
|
|
|
|
|
|
* |
|
|
|
* @return 父容器 |
|
|
|
* @return 父容器 |
|
|
|
*/ |
|
|
|
*/ |
|
|
|
public Component getTopContainer() { |
|
|
|
public Component getTopContainer() { |
|
|
@ -437,6 +444,7 @@ public class FormDesigner extends TargetComponent<Form> implements TreeSelection |
|
|
|
|
|
|
|
|
|
|
|
/** |
|
|
|
/** |
|
|
|
* 返回参数界面高度 |
|
|
|
* 返回参数界面高度 |
|
|
|
|
|
|
|
* |
|
|
|
* @return para高度 |
|
|
|
* @return para高度 |
|
|
|
*/ |
|
|
|
*/ |
|
|
|
public int getParaHeight() { |
|
|
|
public int getParaHeight() { |
|
|
@ -445,6 +453,7 @@ public class FormDesigner extends TargetComponent<Form> implements TreeSelection |
|
|
|
|
|
|
|
|
|
|
|
/** |
|
|
|
/** |
|
|
|
* 重置para的高度 |
|
|
|
* 重置para的高度 |
|
|
|
|
|
|
|
* |
|
|
|
* @param height 高度 |
|
|
|
* @param height 高度 |
|
|
|
*/ |
|
|
|
*/ |
|
|
|
public void setParaHeight(int height) { |
|
|
|
public void setParaHeight(int height) { |
|
|
@ -472,6 +481,7 @@ public class FormDesigner extends TargetComponent<Form> implements TreeSelection |
|
|
|
|
|
|
|
|
|
|
|
/** |
|
|
|
/** |
|
|
|
* 切换 |
|
|
|
* 切换 |
|
|
|
|
|
|
|
* |
|
|
|
* @param elementCaseContainer 容器 |
|
|
|
* @param elementCaseContainer 容器 |
|
|
|
*/ |
|
|
|
*/ |
|
|
|
public void switchTab(FormElementCaseContainerProvider elementCaseContainer) { |
|
|
|
public void switchTab(FormElementCaseContainerProvider elementCaseContainer) { |
|
|
@ -524,6 +534,7 @@ public class FormDesigner extends TargetComponent<Form> implements TreeSelection |
|
|
|
|
|
|
|
|
|
|
|
/** |
|
|
|
/** |
|
|
|
* 增加监听事件 |
|
|
|
* 增加监听事件 |
|
|
|
|
|
|
|
* |
|
|
|
* @param listener 界面组件编辑事件 |
|
|
|
* @param listener 界面组件编辑事件 |
|
|
|
*/ |
|
|
|
*/ |
|
|
|
public void addDesignerEditListener(DesignerEditListener listener) { |
|
|
|
public void addDesignerEditListener(DesignerEditListener listener) { |
|
|
@ -539,13 +550,13 @@ public class FormDesigner extends TargetComponent<Form> implements TreeSelection |
|
|
|
|
|
|
|
|
|
|
|
/** |
|
|
|
/** |
|
|
|
* 表单则判断参数面板是否为绝对布局 |
|
|
|
* 表单则判断参数面板是否为绝对布局 |
|
|
|
|
|
|
|
* |
|
|
|
* @return 是则返回true |
|
|
|
* @return 是则返回true |
|
|
|
*/ |
|
|
|
*/ |
|
|
|
public boolean hasWAbsoluteLayout() { |
|
|
|
public boolean hasWAbsoluteLayout() { |
|
|
|
if (paraComponent != null && paraComponent.acceptType(XWParameterLayout.class)) { |
|
|
|
if (paraComponent != null && paraComponent.acceptType(XWParameterLayout.class)) { |
|
|
|
return true; |
|
|
|
return true; |
|
|
|
} |
|
|
|
} else { |
|
|
|
else{ |
|
|
|
|
|
|
|
if (this.getSelectionModel().getSelection().getSelectedCreator().getParent() != null |
|
|
|
if (this.getSelectionModel().getSelection().getSelectedCreator().getParent() != null |
|
|
|
&& ((XLayoutContainer) this.getSelectionModel().getSelection().getSelectedCreator().getParent()).acceptType(XWAbsoluteLayout.class)) { |
|
|
|
&& ((XLayoutContainer) this.getSelectionModel().getSelection().getSelectedCreator().getParent()).acceptType(XWAbsoluteLayout.class)) { |
|
|
|
return true; |
|
|
|
return true; |
|
|
@ -556,6 +567,7 @@ public class FormDesigner extends TargetComponent<Form> implements TreeSelection |
|
|
|
|
|
|
|
|
|
|
|
/** |
|
|
|
/** |
|
|
|
* 设置是否为报表块编辑 |
|
|
|
* 设置是否为报表块编辑 |
|
|
|
|
|
|
|
* |
|
|
|
* @param isEditing 是否为报表块编辑 |
|
|
|
* @param isEditing 是否为报表块编辑 |
|
|
|
*/ |
|
|
|
*/ |
|
|
|
public void setReportBlockEditing(boolean isEditing) { |
|
|
|
public void setReportBlockEditing(boolean isEditing) { |
|
|
@ -564,6 +576,7 @@ public class FormDesigner extends TargetComponent<Form> implements TreeSelection |
|
|
|
|
|
|
|
|
|
|
|
/** |
|
|
|
/** |
|
|
|
* 是否为报表块编辑 |
|
|
|
* 是否为报表块编辑 |
|
|
|
|
|
|
|
* |
|
|
|
* @return 是否为报表块编辑 |
|
|
|
* @return 是否为报表块编辑 |
|
|
|
*/ |
|
|
|
*/ |
|
|
|
public boolean isReportBlockEditing() { |
|
|
|
public boolean isReportBlockEditing() { |
|
|
@ -580,6 +593,7 @@ public class FormDesigner extends TargetComponent<Form> implements TreeSelection |
|
|
|
|
|
|
|
|
|
|
|
/** |
|
|
|
/** |
|
|
|
* 是否重命名控件 |
|
|
|
* 是否重命名控件 |
|
|
|
|
|
|
|
* |
|
|
|
* @param creator 组件 |
|
|
|
* @param creator 组件 |
|
|
|
* @param newName 新的组件名 |
|
|
|
* @param newName 新的组件名 |
|
|
|
* @return 组件名有变化,且不和其他一样返回true |
|
|
|
* @return 组件名有变化,且不和其他一样返回true |
|
|
@ -609,6 +623,7 @@ public class FormDesigner extends TargetComponent<Form> implements TreeSelection |
|
|
|
|
|
|
|
|
|
|
|
/** |
|
|
|
/** |
|
|
|
* 更新界面布局,重绘 |
|
|
|
* 更新界面布局,重绘 |
|
|
|
|
|
|
|
* |
|
|
|
* @param proxy 动态代理类 |
|
|
|
* @param proxy 动态代理类 |
|
|
|
* @param method 接口方法 |
|
|
|
* @param method 接口方法 |
|
|
|
* @param args 参数 |
|
|
|
* @param args 参数 |
|
|
@ -654,6 +669,7 @@ public class FormDesigner extends TargetComponent<Form> implements TreeSelection |
|
|
|
|
|
|
|
|
|
|
|
/** |
|
|
|
/** |
|
|
|
* 增加组件事件 |
|
|
|
* 增加组件事件 |
|
|
|
|
|
|
|
* |
|
|
|
* @param h 动态代理 |
|
|
|
* @param h 动态代理 |
|
|
|
*/ |
|
|
|
*/ |
|
|
|
public void addInvocationHandler(InvocationHandler h) { |
|
|
|
public void addInvocationHandler(InvocationHandler h) { |
|
|
@ -741,16 +757,14 @@ public class FormDesigner extends TargetComponent<Form> implements TreeSelection |
|
|
|
|
|
|
|
|
|
|
|
/** |
|
|
|
/** |
|
|
|
* 更新边框线状态 |
|
|
|
* 更新边框线状态 |
|
|
|
|
|
|
|
* |
|
|
|
* @param e 鼠标事件 |
|
|
|
* @param e 鼠标事件 |
|
|
|
*/ |
|
|
|
*/ |
|
|
|
public void updateDrawLineMode(MouseEvent e) { |
|
|
|
public void updateDrawLineMode(MouseEvent e) { |
|
|
|
Point p = ConnectorHelper.getNearWidgetPoint(e); |
|
|
|
Point p = connectorHelper.getNearWidgetPoint(e); |
|
|
|
if (p == null) { |
|
|
|
if (p == null && getComponentAt(e) == rootComponent) { |
|
|
|
XComponent comp = getComponentAt(e); |
|
|
|
|
|
|
|
if (comp == rootComponent) { |
|
|
|
|
|
|
|
p = new Point(e.getX() + formArea.getHorizontalValue(), e.getY() + formArea.getVerticalValue()); |
|
|
|
p = new Point(e.getX() + formArea.getHorizontalValue(), e.getY() + formArea.getVerticalValue()); |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
stateModel.startDrawLine(p); |
|
|
|
stateModel.startDrawLine(p); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
@ -841,6 +855,7 @@ public class FormDesigner extends TargetComponent<Form> implements TreeSelection |
|
|
|
|
|
|
|
|
|
|
|
/** |
|
|
|
/** |
|
|
|
* 是否是报表的参数面板 |
|
|
|
* 是否是报表的参数面板 |
|
|
|
|
|
|
|
* |
|
|
|
* @return 否(表单的) |
|
|
|
* @return 否(表单的) |
|
|
|
*/ |
|
|
|
*/ |
|
|
|
public boolean isFormParaDesigner() { |
|
|
|
public boolean isFormParaDesigner() { |
|
|
@ -849,6 +864,7 @@ public class FormDesigner extends TargetComponent<Form> implements TreeSelection |
|
|
|
|
|
|
|
|
|
|
|
/** |
|
|
|
/** |
|
|
|
* 是否为底层容器 |
|
|
|
* 是否为底层容器 |
|
|
|
|
|
|
|
* |
|
|
|
* @param comp 组件 |
|
|
|
* @param comp 组件 |
|
|
|
* @return 是则返回true |
|
|
|
* @return 是则返回true |
|
|
|
*/ |
|
|
|
*/ |
|
|
@ -941,6 +957,7 @@ public class FormDesigner extends TargetComponent<Form> implements TreeSelection |
|
|
|
|
|
|
|
|
|
|
|
/** |
|
|
|
/** |
|
|
|
* 拖拽准备 |
|
|
|
* 拖拽准备 |
|
|
|
|
|
|
|
* |
|
|
|
* @param xCreator 组件 |
|
|
|
* @param xCreator 组件 |
|
|
|
*/ |
|
|
|
*/ |
|
|
|
public void startDraggingBean(XCreator xCreator) { |
|
|
|
public void startDraggingBean(XCreator xCreator) { |
|
|
@ -954,6 +971,7 @@ public class FormDesigner extends TargetComponent<Form> implements TreeSelection |
|
|
|
|
|
|
|
|
|
|
|
/** |
|
|
|
/** |
|
|
|
* 拖拽时相关处理 |
|
|
|
* 拖拽时相关处理 |
|
|
|
|
|
|
|
* |
|
|
|
* @param xCreator 组件 |
|
|
|
* @param xCreator 组件 |
|
|
|
* @param lastPressEvent 鼠标事件 |
|
|
|
* @param lastPressEvent 鼠标事件 |
|
|
|
* @param x 坐标x |
|
|
|
* @param x 坐标x |
|
|
@ -978,6 +996,7 @@ public class FormDesigner extends TargetComponent<Form> implements TreeSelection |
|
|
|
|
|
|
|
|
|
|
|
/** |
|
|
|
/** |
|
|
|
* 改变组件值 |
|
|
|
* 改变组件值 |
|
|
|
|
|
|
|
* |
|
|
|
* @param e 组件选择事件 |
|
|
|
* @param e 组件选择事件 |
|
|
|
*/ |
|
|
|
*/ |
|
|
|
@Override |
|
|
|
@Override |
|
|
@ -1024,6 +1043,7 @@ public class FormDesigner extends TargetComponent<Form> implements TreeSelection |
|
|
|
|
|
|
|
|
|
|
|
/** |
|
|
|
/** |
|
|
|
* 是否支持权限编辑 |
|
|
|
* 是否支持权限编辑 |
|
|
|
|
|
|
|
* |
|
|
|
* @return 是则返回true |
|
|
|
* @return 是则返回true |
|
|
|
*/ |
|
|
|
*/ |
|
|
|
public boolean isSupportAuthority() { |
|
|
|
public boolean isSupportAuthority() { |
|
|
@ -1049,6 +1069,7 @@ public class FormDesigner extends TargetComponent<Form> implements TreeSelection |
|
|
|
|
|
|
|
|
|
|
|
/** |
|
|
|
/** |
|
|
|
* 是否含有action名 |
|
|
|
* 是否含有action名 |
|
|
|
|
|
|
|
* |
|
|
|
* @param name action名 |
|
|
|
* @param name action名 |
|
|
|
* @return 有则返回true |
|
|
|
* @return 有则返回true |
|
|
|
*/ |
|
|
|
*/ |
|
|
@ -1058,6 +1079,7 @@ public class FormDesigner extends TargetComponent<Form> implements TreeSelection |
|
|
|
|
|
|
|
|
|
|
|
/** |
|
|
|
/** |
|
|
|
* 显示组件 |
|
|
|
* 显示组件 |
|
|
|
|
|
|
|
* |
|
|
|
* @param comp 组件 |
|
|
|
* @param comp 组件 |
|
|
|
*/ |
|
|
|
*/ |
|
|
|
public void makeVisible(XCreator comp) { |
|
|
|
public void makeVisible(XCreator comp) { |
|
|
@ -1088,16 +1110,16 @@ public class FormDesigner extends TargetComponent<Form> implements TreeSelection |
|
|
|
|
|
|
|
|
|
|
|
/** |
|
|
|
/** |
|
|
|
* 返回复制粘贴删除等动作 |
|
|
|
* 返回复制粘贴删除等动作 |
|
|
|
|
|
|
|
* 鼠标右键菜单 |
|
|
|
|
|
|
|
* |
|
|
|
* @return 同上 |
|
|
|
* @return 同上 |
|
|
|
*/ |
|
|
|
*/ |
|
|
|
public Action[] getActions() { |
|
|
|
public Action[] getActions() { |
|
|
|
if (designer_actions == null) { |
|
|
|
if (designerActions == null) { |
|
|
|
//先把复制粘贴按钮去掉,只留下删除
|
|
|
|
designerActions = new Action[]{new CutAction(this), new CopyAction(this), new PasteAction(this), |
|
|
|
// designer_actions = new Action[]{new CutAction(this), new CopyAction(this), new PasteAction(this),
|
|
|
|
new FormDeleteAction(this)}; |
|
|
|
// new FormDeleteAction(this)};
|
|
|
|
|
|
|
|
designer_actions = new Action[]{new FormDeleteAction(this)}; |
|
|
|
|
|
|
|
} |
|
|
|
} |
|
|
|
return designer_actions; |
|
|
|
return designerActions; |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
protected Border getOuterBorder() { |
|
|
|
protected Border getOuterBorder() { |
|
|
@ -1120,6 +1142,7 @@ public class FormDesigner extends TargetComponent<Form> implements TreeSelection |
|
|
|
|
|
|
|
|
|
|
|
/** |
|
|
|
/** |
|
|
|
* 返回表单区域 |
|
|
|
* 返回表单区域 |
|
|
|
|
|
|
|
* |
|
|
|
* @return 表单区域 |
|
|
|
* @return 表单区域 |
|
|
|
*/ |
|
|
|
*/ |
|
|
|
public FormArea getArea() { |
|
|
|
public FormArea getArea() { |
|
|
@ -1128,6 +1151,7 @@ public class FormDesigner extends TargetComponent<Form> implements TreeSelection |
|
|
|
|
|
|
|
|
|
|
|
/** |
|
|
|
/** |
|
|
|
* 设置上层区域 |
|
|
|
* 设置上层区域 |
|
|
|
|
|
|
|
* |
|
|
|
* @param formArea 表单区域 |
|
|
|
* @param formArea 表单区域 |
|
|
|
*/ |
|
|
|
*/ |
|
|
|
public void setParent(FormArea formArea) { |
|
|
|
public void setParent(FormArea formArea) { |
|
|
@ -1136,6 +1160,7 @@ public class FormDesigner extends TargetComponent<Form> implements TreeSelection |
|
|
|
|
|
|
|
|
|
|
|
/** |
|
|
|
/** |
|
|
|
* 绘制组件根节点 |
|
|
|
* 绘制组件根节点 |
|
|
|
|
|
|
|
* |
|
|
|
* @param clipg 图形 |
|
|
|
* @param clipg 图形 |
|
|
|
*/ |
|
|
|
*/ |
|
|
|
public void paintContent(Graphics clipg) { |
|
|
|
public void paintContent(Graphics clipg) { |
|
|
@ -1157,14 +1182,16 @@ public class FormDesigner extends TargetComponent<Form> implements TreeSelection |
|
|
|
|
|
|
|
|
|
|
|
/** |
|
|
|
/** |
|
|
|
* 返回连线类 |
|
|
|
* 返回连线类 |
|
|
|
|
|
|
|
* |
|
|
|
* @return ConnectorHelper类 |
|
|
|
* @return ConnectorHelper类 |
|
|
|
*/ |
|
|
|
*/ |
|
|
|
public ConnectorHelper getDrawLineHelper() { |
|
|
|
public ConnectorHelper getDrawLineHelper() { |
|
|
|
return ConnectorHelper; |
|
|
|
return connectorHelper; |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
/** |
|
|
|
/** |
|
|
|
* 是否画线模式 |
|
|
|
* 是否画线模式 |
|
|
|
|
|
|
|
* |
|
|
|
* @return 是则返回true |
|
|
|
* @return 是则返回true |
|
|
|
*/ |
|
|
|
*/ |
|
|
|
public boolean isDrawLineMode() { |
|
|
|
public boolean isDrawLineMode() { |
|
|
@ -1173,6 +1200,7 @@ public class FormDesigner extends TargetComponent<Form> implements TreeSelection |
|
|
|
|
|
|
|
|
|
|
|
/** |
|
|
|
/** |
|
|
|
* 设置DrawLineMode |
|
|
|
* 设置DrawLineMode |
|
|
|
|
|
|
|
* |
|
|
|
* @param mode 是or或 |
|
|
|
* @param mode 是or或 |
|
|
|
*/ |
|
|
|
*/ |
|
|
|
public void setDrawLineMode(boolean mode) { |
|
|
|
public void setDrawLineMode(boolean mode) { |
|
|
@ -1199,6 +1227,7 @@ public class FormDesigner extends TargetComponent<Form> implements TreeSelection |
|
|
|
|
|
|
|
|
|
|
|
/** |
|
|
|
/** |
|
|
|
* 返回表单控件权限编辑pane |
|
|
|
* 返回表单控件权限编辑pane |
|
|
|
|
|
|
|
* |
|
|
|
* @return 同上 |
|
|
|
* @return 同上 |
|
|
|
*/ |
|
|
|
*/ |
|
|
|
public AuthorityEditPane createAuthorityEditPane() { |
|
|
|
public AuthorityEditPane createAuthorityEditPane() { |
|
|
@ -1249,6 +1278,7 @@ public class FormDesigner extends TargetComponent<Form> implements TreeSelection |
|
|
|
|
|
|
|
|
|
|
|
/** |
|
|
|
/** |
|
|
|
* 粘贴 |
|
|
|
* 粘贴 |
|
|
|
|
|
|
|
* |
|
|
|
* @return 否 |
|
|
|
* @return 否 |
|
|
|
*/ |
|
|
|
*/ |
|
|
|
@Override |
|
|
|
@Override |
|
|
@ -1259,6 +1289,7 @@ public class FormDesigner extends TargetComponent<Form> implements TreeSelection |
|
|
|
|
|
|
|
|
|
|
|
/** |
|
|
|
/** |
|
|
|
* 剪切 |
|
|
|
* 剪切 |
|
|
|
|
|
|
|
* |
|
|
|
* @return 否 |
|
|
|
* @return 否 |
|
|
|
*/ |
|
|
|
*/ |
|
|
|
@Override |
|
|
|
@Override |
|
|
@ -1273,6 +1304,7 @@ public class FormDesigner extends TargetComponent<Form> implements TreeSelection |
|
|
|
|
|
|
|
|
|
|
|
/** |
|
|
|
/** |
|
|
|
* 工具栏菜单 |
|
|
|
* 工具栏菜单 |
|
|
|
|
|
|
|
* |
|
|
|
* @return 同上 |
|
|
|
* @return 同上 |
|
|
|
*/ |
|
|
|
*/ |
|
|
|
@Override |
|
|
|
@Override |
|
|
@ -1286,6 +1318,7 @@ public class FormDesigner extends TargetComponent<Form> implements TreeSelection |
|
|
|
|
|
|
|
|
|
|
|
/** |
|
|
|
/** |
|
|
|
* 模版菜单 |
|
|
|
* 模版菜单 |
|
|
|
|
|
|
|
* |
|
|
|
* @return 同上 |
|
|
|
* @return 同上 |
|
|
|
*/ |
|
|
|
*/ |
|
|
|
@Override |
|
|
|
@Override |
|
|
@ -1295,6 +1328,7 @@ public class FormDesigner extends TargetComponent<Form> implements TreeSelection |
|
|
|
|
|
|
|
|
|
|
|
/** |
|
|
|
/** |
|
|
|
* 权限菜单 |
|
|
|
* 权限菜单 |
|
|
|
|
|
|
|
* |
|
|
|
* @return 同上 |
|
|
|
* @return 同上 |
|
|
|
*/ |
|
|
|
*/ |
|
|
|
public ShortCut[] shortCuts4Authority() { |
|
|
|
public ShortCut[] shortCuts4Authority() { |
|
|
@ -1304,6 +1338,7 @@ public class FormDesigner extends TargetComponent<Form> implements TreeSelection |
|
|
|
|
|
|
|
|
|
|
|
/** |
|
|
|
/** |
|
|
|
* 返回ToolBarDef |
|
|
|
* 返回ToolBarDef |
|
|
|
|
|
|
|
* |
|
|
|
* @return 同上 |
|
|
|
* @return 同上 |
|
|
|
*/ |
|
|
|
*/ |
|
|
|
@Override |
|
|
|
@Override |
|
|
@ -1313,10 +1348,12 @@ public class FormDesigner extends TargetComponent<Form> implements TreeSelection |
|
|
|
|
|
|
|
|
|
|
|
/** |
|
|
|
/** |
|
|
|
* 返回工具栏按钮组件 |
|
|
|
* 返回工具栏按钮组件 |
|
|
|
|
|
|
|
* |
|
|
|
* @return 同上 |
|
|
|
* @return 同上 |
|
|
|
*/ |
|
|
|
*/ |
|
|
|
public JComponent[] toolBarButton4Form() { |
|
|
|
public JComponent[] toolBarButton4Form() { |
|
|
|
return new JComponent[0]; |
|
|
|
return new JComponent[]{new CutAction(this).createToolBarComponent(), new CopyAction(this).createToolBarComponent(), new PasteAction(this).createToolBarComponent(), |
|
|
|
|
|
|
|
new FormDeleteAction(this).createToolBarComponent()}; |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|