From a97ae8cc0e487e76cff3cb0760cc1bbf7dbefe9e Mon Sep 17 00:00:00 2001 From: zpc Date: Thu, 21 Jul 2016 17:14:45 +0800 Subject: [PATCH 1/6] =?UTF-8?q?=E5=8E=BB=E6=8E=89qq=E5=B8=AE=E5=8A=A9?= =?UTF-8?q?=EF=BC=8C=E5=B9=B6=E5=9C=A8=E5=85=B3=E4=BA=8E=E8=BD=AF=E4=BB=B6?= =?UTF-8?q?=E4=B8=AD=E6=98=BE=E7=A4=BAqq=E5=8F=B7=E7=A0=81=EF=BC=8C?= =?UTF-8?q?=E5=86=BB=E7=BB=93=E6=97=B6=E7=BB=99=E6=8F=90=E7=A4=BA?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 去掉qq帮助,并在关于软件中显示qq号码,冻结时给提示 --- .../freeze/RepeatAndFreezeSettingPane.java | 77 ++++++++++++++++++- .../com/fr/design/actions/help/AboutPane.java | 3 + .../mainframe/toolbar/ToolBarMenuDock.java | 2 +- 3 files changed, 77 insertions(+), 5 deletions(-) diff --git a/designer/src/com/fr/design/report/freeze/RepeatAndFreezeSettingPane.java b/designer/src/com/fr/design/report/freeze/RepeatAndFreezeSettingPane.java index f707e0500..3fa4d349a 100644 --- a/designer/src/com/fr/design/report/freeze/RepeatAndFreezeSettingPane.java +++ b/designer/src/com/fr/design/report/freeze/RepeatAndFreezeSettingPane.java @@ -1,17 +1,23 @@ package com.fr.design.report.freeze; -import java.awt.BorderLayout; -import java.awt.Color; +import java.awt.*; +import java.awt.event.ActionEvent; +import java.awt.event.ActionListener; -import javax.swing.BorderFactory; -import javax.swing.JPanel; +import javax.swing.*; import javax.swing.event.ChangeEvent; import javax.swing.event.ChangeListener; import com.fr.design.dialog.BasicPane; +import com.fr.design.dialog.UIDialog; +import com.fr.design.extra.PluginManagerPane; +import com.fr.design.extra.PluginShopDialog; +import com.fr.design.extra.PluginWebBridge; import com.fr.design.gui.icheckbox.UICheckBox; +import com.fr.design.gui.ilable.ActionLabel; import com.fr.design.gui.ilable.UILabel; import com.fr.design.layout.FRGUIPaneFactory; +import com.fr.design.mainframe.DesignerContext; import com.fr.general.Inter; import com.fr.page.ReportPageAttrProvider; import com.fr.stable.ColumnRow; @@ -51,6 +57,7 @@ public class RepeatAndFreezeSettingPane extends BasicPane { // 填报冻结 private UICheckBox useWriteFrozenCCheckBox; private UICheckBox useWriteFrozenRCheckBox; + private static final int LABEL_HEIGHT = 45; /** * 重复标题行 @@ -206,7 +213,15 @@ public class RepeatAndFreezeSettingPane extends BasicPane { JPanel repeatPanel = FRGUIPaneFactory.createNColumnGridInnerContainer_S_Pane(1); repeatPanel.setBorder(BorderFactory.createEmptyBorder(0, 20, 0, 0)); JPanel freezePanel = FRGUIPaneFactory.createBorderLayout_S_Pane(); + + //自适应插件 + JPanel infoPane = FRGUIPaneFactory.createTitledBorderPane(Inter.getLocText("Attention")); + + BoxCenterAligmentPane actionLabel = getURLActionLabel(Inter.getLocText("FR-Designer_Form-Fit-Tip")); + infoPane.add(actionLabel, BorderLayout.SOUTH); + outfreezePanel.add(freezePanel); + this.add(infoPane, BorderLayout.SOUTH); // 重复打印部分 // 重复打印标题的起始行 JPanel labelPanel = FRGUIPaneFactory.createNormalFlowInnerContainer_S_Pane(); @@ -536,4 +551,58 @@ public class RepeatAndFreezeSettingPane extends BasicPane { return null; } + private BoxCenterAligmentPane getURLActionLabel(final String text) { + ActionLabel actionLabel = new ActionLabel(text); + + actionLabel.addActionListener(new ActionListener() { + @Override + public void actionPerformed(ActionEvent e) { + try { + //Desktop.getDesktop().browse(new URI(url)); + final PluginManagerPane managerPane = new PluginManagerPane(); + UIDialog dlg = new PluginShopDialog(DesignerContext.getDesignerFrame(),managerPane); + PluginWebBridge.getHelper().setDialogHandle(dlg); + dlg.setVisible(true); + RepeatAndFreezeSettingPane.this.getTopLevelAncestor().setVisible(false); + } catch (Exception exp) { + + } + } + }); + + return new BoxCenterAligmentPane(actionLabel); + } + + class BoxCenterAligmentPane extends JPanel { + + private UILabel textLabel; + + public BoxCenterAligmentPane(String text) { + this(new UILabel(text)); + } + + public BoxCenterAligmentPane(UILabel label) { + this.setLayout(FRGUIPaneFactory.createBorderLayout()); + + JPanel centerPane = FRGUIPaneFactory.createNormalFlowInnerContainer_S_Pane(); + this.add(centerPane, BorderLayout.CENTER); + UILabel label1 = new UILabel(Inter.getLocText("FR-Designer_Form-Frozen-Tip")); + label1.setForeground(new Color(255, 0, 0)); + UILabel label2 = new UILabel(Inter.getLocText("FR-Designer_Form-Forzen-Speed")); + label2.setForeground(new Color(255, 0, 0)); + this.textLabel = label; + centerPane.add(label1); + centerPane.add(textLabel); + centerPane.add(label2); + } + + public void setFont(Font font) { + super.setFont(font); + + if (textLabel != null) { + textLabel.setFont(font); + } + } + } + } \ No newline at end of file diff --git a/designer_base/src/com/fr/design/actions/help/AboutPane.java b/designer_base/src/com/fr/design/actions/help/AboutPane.java index caa319088..680aa9b95 100644 --- a/designer_base/src/com/fr/design/actions/help/AboutPane.java +++ b/designer_base/src/com/fr/design/actions/help/AboutPane.java @@ -11,6 +11,7 @@ import com.fr.design.layout.FRGUIPaneFactory; import com.fr.general.ComparatorUtils; import com.fr.general.GeneralUtils; import com.fr.general.Inter; +import com.fr.general.SiteCenter; import com.fr.stable.ProductConstants; import com.fr.stable.StringUtils; import com.fr.stable.bridge.StableFactory; @@ -69,6 +70,8 @@ public class AboutPane extends JPanel { boxCenterAlignmentPane = new BoxCenterAligmentPane(Inter.getLocText("Service_Phone") + ProductConstants.COMPARE_TELEPHONE); contentPane.add(boxCenterAlignmentPane); } + boxCenterAlignmentPane = new BoxCenterAligmentPane("QQ:" + SiteCenter.getInstance().acquireUrlByKind("help.qq")); + contentPane.add(boxCenterAlignmentPane); BoxCenterAligmentPane actionLabel = getURLActionLabel(ProductConstants.WEBSITE_URL); BoxCenterAligmentPane emailLabel = getEmailActionLabel(ProductConstants.SUPPORT_EMAIL); diff --git a/designer_base/src/com/fr/design/mainframe/toolbar/ToolBarMenuDock.java b/designer_base/src/com/fr/design/mainframe/toolbar/ToolBarMenuDock.java index f0b1eac9f..364a11cee 100644 --- a/designer_base/src/com/fr/design/mainframe/toolbar/ToolBarMenuDock.java +++ b/designer_base/src/com/fr/design/mainframe/toolbar/ToolBarMenuDock.java @@ -301,7 +301,7 @@ public abstract class ToolBarMenuDock { if (ComparatorUtils.equals(ProductConstants.APP_NAME,FINEREPORT)) { shortCuts.add(new FeedBackAction()); shortCuts.add(SeparatorDef.DEFAULT); - shortCuts.add(new SupportQQAction()); + //shortCuts.add(new SupportQQAction()); shortCuts.add(SeparatorDef.DEFAULT); // shortCuts.add(new ForumAction()); } From 7b6df7ae61d5da9c73b5ed4fb67d8458e3809088 Mon Sep 17 00:00:00 2001 From: zpc Date: Fri, 22 Jul 2016 13:02:09 +0800 Subject: [PATCH 2/6] =?UTF-8?q?=E8=A3=85=E4=BA=86=E6=8F=92=E4=BB=B6?= =?UTF-8?q?=E5=90=8E,=20=E5=8F=AF=E4=BB=A5=E8=AE=BE=E7=BD=AE=E6=98=BE?= =?UTF-8?q?=E7=A4=BA=E6=88=96=E8=80=85=E4=B8=8D=E6=98=BE=E7=A4=BA?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 装了插件后, 可以设置显示或者不显示 --- .../fr/design/fun/ShowParameterWindow.java | 20 +++++++++++++ .../AbstractShowParameterWindowProvider.java | 30 +++++++++++++++++++ .../designer/creator/XWParameterLayout.java | 26 ++++++++++++++-- 3 files changed, 74 insertions(+), 2 deletions(-) create mode 100644 designer_base/src/com/fr/design/fun/ShowParameterWindow.java create mode 100644 designer_base/src/com/fr/design/fun/impl/AbstractShowParameterWindowProvider.java diff --git a/designer_base/src/com/fr/design/fun/ShowParameterWindow.java b/designer_base/src/com/fr/design/fun/ShowParameterWindow.java new file mode 100644 index 000000000..6775deaa4 --- /dev/null +++ b/designer_base/src/com/fr/design/fun/ShowParameterWindow.java @@ -0,0 +1,20 @@ +package com.fr.design.fun; + +import com.fr.stable.fun.mark.Immutable; + + +/** + * Created by zpc on 16/7/21. + */ +public interface ShowParameterWindow extends Immutable { + + String MARK_STRING = "ShowParameter"; + + int CURRENT_LEVEL = 1; + + /** + * 生成属性表 + */ + void add(); +} + diff --git a/designer_base/src/com/fr/design/fun/impl/AbstractShowParameterWindowProvider.java b/designer_base/src/com/fr/design/fun/impl/AbstractShowParameterWindowProvider.java new file mode 100644 index 000000000..98d7d92b4 --- /dev/null +++ b/designer_base/src/com/fr/design/fun/impl/AbstractShowParameterWindowProvider.java @@ -0,0 +1,30 @@ +package com.fr.design.fun.impl; + +import com.fr.design.fun.ShowParameterWindow; +import com.fr.stable.fun.mark.API; + + +/** + * Created by zpc on 2016/7/21. + */ +@API(level = ShowParameterWindow.CURRENT_LEVEL) +public abstract class AbstractShowParameterWindowProvider implements ShowParameterWindow { + + public int currentAPILevel() { + return CURRENT_LEVEL; + } + + public int layerIndex() { + return DEFAULT_LAYER_INDEX; + } + + + + /** + * 生成属性表 + */ + @Override + public void add() { + + } +} \ No newline at end of file diff --git a/designer_form/src/com/fr/design/designer/creator/XWParameterLayout.java b/designer_form/src/com/fr/design/designer/creator/XWParameterLayout.java index 9f92b9786..1b57aa565 100644 --- a/designer_form/src/com/fr/design/designer/creator/XWParameterLayout.java +++ b/designer_form/src/com/fr/design/designer/creator/XWParameterLayout.java @@ -3,6 +3,7 @@ */ package com.fr.design.designer.creator; +import com.fr.design.ExtraDesignClassManager; import com.fr.design.designer.beans.LayoutAdapter; import com.fr.design.designer.beans.adapters.layout.FRParameterLayoutAdapter; import com.fr.design.form.util.XCreatorConstants; @@ -16,6 +17,7 @@ import com.fr.form.ui.container.WFitLayout; import com.fr.form.ui.container.WParameterLayout; import com.fr.general.Background; import com.fr.general.Inter; +import com.fr.design.fun.ShowParameterWindow; import java.awt.*; import java.beans.IntrospectionException; @@ -51,19 +53,39 @@ public class XWParameterLayout extends XWAbsoluteLayout { * @throws java.beans.IntrospectionException */ public CRPropertyDescriptor[] supportedDescriptor() throws IntrospectionException { - return new CRPropertyDescriptor[]{ + ShowParameterWindow processor = ExtraDesignClassManager.getInstance().getSingle(ShowParameterWindow.MARK_STRING); + if (processor == null) { + return new CRPropertyDescriptor[]{ + new CRPropertyDescriptor("widgetName", this.data.getClass()).setI18NName(Inter + .getLocText("FR-Designer_Form-Widget_Name")), + new CRPropertyDescriptor("background", this.data.getClass()).setEditorClass(BackgroundEditor.class) + .setRendererClass(BackgroundRenderer.class).setI18NName(Inter.getLocText("Background")) + .putKeyValue(XCreatorConstants.PROPERTY_CATEGORY, "Advanced"), + new CRPropertyDescriptor("delayDisplayContent", this.data.getClass()).setEditorClass(BooleanEditor.class) + .setI18NName(Inter.getLocText("FR-Designer_DisplayNothingBeforeQuery")) + .putKeyValue(XCreatorConstants.PROPERTY_CATEGORY, "Advanced"), + new CRPropertyDescriptor("position", this.data.getClass()).setEditorClass(WidgetDisplayPosition.class) + .setRendererClass(WidgetDisplayPositionRender.class).setI18NName(Inter.getLocText("FR-Designer_WidgetDisplyPosition")) + .putKeyValue(XCreatorConstants.PROPERTY_CATEGORY, "Advanced"), + }; + } + return new CRPropertyDescriptor[]{ new CRPropertyDescriptor("widgetName", this.data.getClass()).setI18NName(Inter .getLocText("FR-Designer_Form-Widget_Name")), new CRPropertyDescriptor("background", this.data.getClass()).setEditorClass(BackgroundEditor.class) .setRendererClass(BackgroundRenderer.class).setI18NName(Inter.getLocText("Background")) .putKeyValue(XCreatorConstants.PROPERTY_CATEGORY, "Advanced"), + new CRPropertyDescriptor("display", this.data.getClass()).setEditorClass(BooleanEditor.class) + .setI18NName(Inter.getLocText("ParameterD-Show_Parameter_Window")) + .putKeyValue(XCreatorConstants.PROPERTY_CATEGORY, "Advanced"), new CRPropertyDescriptor("delayDisplayContent", this.data.getClass()).setEditorClass(BooleanEditor.class) .setI18NName(Inter.getLocText("FR-Designer_DisplayNothingBeforeQuery")) .putKeyValue(XCreatorConstants.PROPERTY_CATEGORY, "Advanced"), new CRPropertyDescriptor("position", this.data.getClass()).setEditorClass(WidgetDisplayPosition.class) - .setRendererClass(WidgetDisplayPositionRender.class).setI18NName(Inter.getLocText("FR-Designer_WidgetDisplyPosition")) + .setRendererClass(WidgetDisplayPositionRender.class).setI18NName(Inter.getLocText("FR-Designer_WidgetDisplyPosition")) .putKeyValue(XCreatorConstants.PROPERTY_CATEGORY, "Advanced"), }; + } @Override From fd400ec7b66bfc32ee9fcd8ada615f6f7870076e Mon Sep 17 00:00:00 2001 From: zpc Date: Mon, 25 Jul 2016 14:21:15 +0800 Subject: [PATCH 3/6] =?UTF-8?q?=E8=A3=85=E4=BA=86=E6=8F=92=E4=BB=B6?= =?UTF-8?q?=E5=90=8E,=20=E5=8F=AF=E4=BB=A5=E8=AE=BE=E7=BD=AE=E6=98=BE?= =?UTF-8?q?=E7=A4=BA=E6=88=96=E8=80=85=E4=B8=8D=E6=98=BE=E7=A4=BA?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 装了插件后, 可以设置显示或者不显示 --- .../fr/design/fun/ShowParameterWindow.java | 3 +- .../AbstractShowParameterWindowProvider.java | 5 ++-- .../designer/creator/XWParameterLayout.java | 30 +++++++------------ 3 files changed, 15 insertions(+), 23 deletions(-) diff --git a/designer_base/src/com/fr/design/fun/ShowParameterWindow.java b/designer_base/src/com/fr/design/fun/ShowParameterWindow.java index 6775deaa4..c8cacb1f0 100644 --- a/designer_base/src/com/fr/design/fun/ShowParameterWindow.java +++ b/designer_base/src/com/fr/design/fun/ShowParameterWindow.java @@ -1,6 +1,7 @@ package com.fr.design.fun; import com.fr.stable.fun.mark.Immutable; +import java.beans.PropertyDescriptor; /** @@ -15,6 +16,6 @@ public interface ShowParameterWindow extends Immutable { /** * 生成属性表 */ - void add(); + PropertyDescriptor[] add(Class temp); } diff --git a/designer_base/src/com/fr/design/fun/impl/AbstractShowParameterWindowProvider.java b/designer_base/src/com/fr/design/fun/impl/AbstractShowParameterWindowProvider.java index 98d7d92b4..6eec6e54b 100644 --- a/designer_base/src/com/fr/design/fun/impl/AbstractShowParameterWindowProvider.java +++ b/designer_base/src/com/fr/design/fun/impl/AbstractShowParameterWindowProvider.java @@ -2,6 +2,7 @@ package com.fr.design.fun.impl; import com.fr.design.fun.ShowParameterWindow; import com.fr.stable.fun.mark.API; +import java.beans.PropertyDescriptor; /** @@ -24,7 +25,7 @@ public abstract class AbstractShowParameterWindowProvider implements ShowParamet * 生成属性表 */ @Override - public void add() { - + public PropertyDescriptor[] add(Class temp) { + return null; } } \ No newline at end of file diff --git a/designer_form/src/com/fr/design/designer/creator/XWParameterLayout.java b/designer_form/src/com/fr/design/designer/creator/XWParameterLayout.java index 1b57aa565..58e9dd455 100644 --- a/designer_form/src/com/fr/design/designer/creator/XWParameterLayout.java +++ b/designer_form/src/com/fr/design/designer/creator/XWParameterLayout.java @@ -18,9 +18,11 @@ import com.fr.form.ui.container.WParameterLayout; import com.fr.general.Background; import com.fr.general.Inter; import com.fr.design.fun.ShowParameterWindow; +import com.fr.stable.ArrayUtils; import java.awt.*; import java.beans.IntrospectionException; +import java.beans.PropertyDescriptor; /** * 表单参数界面container @@ -53,31 +55,12 @@ public class XWParameterLayout extends XWAbsoluteLayout { * @throws java.beans.IntrospectionException */ public CRPropertyDescriptor[] supportedDescriptor() throws IntrospectionException { - ShowParameterWindow processor = ExtraDesignClassManager.getInstance().getSingle(ShowParameterWindow.MARK_STRING); - if (processor == null) { - return new CRPropertyDescriptor[]{ - new CRPropertyDescriptor("widgetName", this.data.getClass()).setI18NName(Inter - .getLocText("FR-Designer_Form-Widget_Name")), - new CRPropertyDescriptor("background", this.data.getClass()).setEditorClass(BackgroundEditor.class) - .setRendererClass(BackgroundRenderer.class).setI18NName(Inter.getLocText("Background")) - .putKeyValue(XCreatorConstants.PROPERTY_CATEGORY, "Advanced"), - new CRPropertyDescriptor("delayDisplayContent", this.data.getClass()).setEditorClass(BooleanEditor.class) - .setI18NName(Inter.getLocText("FR-Designer_DisplayNothingBeforeQuery")) - .putKeyValue(XCreatorConstants.PROPERTY_CATEGORY, "Advanced"), - new CRPropertyDescriptor("position", this.data.getClass()).setEditorClass(WidgetDisplayPosition.class) - .setRendererClass(WidgetDisplayPositionRender.class).setI18NName(Inter.getLocText("FR-Designer_WidgetDisplyPosition")) - .putKeyValue(XCreatorConstants.PROPERTY_CATEGORY, "Advanced"), - }; - } - return new CRPropertyDescriptor[]{ + CRPropertyDescriptor[] propertyTableEditor = new CRPropertyDescriptor[]{ new CRPropertyDescriptor("widgetName", this.data.getClass()).setI18NName(Inter .getLocText("FR-Designer_Form-Widget_Name")), new CRPropertyDescriptor("background", this.data.getClass()).setEditorClass(BackgroundEditor.class) .setRendererClass(BackgroundRenderer.class).setI18NName(Inter.getLocText("Background")) .putKeyValue(XCreatorConstants.PROPERTY_CATEGORY, "Advanced"), - new CRPropertyDescriptor("display", this.data.getClass()).setEditorClass(BooleanEditor.class) - .setI18NName(Inter.getLocText("ParameterD-Show_Parameter_Window")) - .putKeyValue(XCreatorConstants.PROPERTY_CATEGORY, "Advanced"), new CRPropertyDescriptor("delayDisplayContent", this.data.getClass()).setEditorClass(BooleanEditor.class) .setI18NName(Inter.getLocText("FR-Designer_DisplayNothingBeforeQuery")) .putKeyValue(XCreatorConstants.PROPERTY_CATEGORY, "Advanced"), @@ -86,6 +69,13 @@ public class XWParameterLayout extends XWAbsoluteLayout { .putKeyValue(XCreatorConstants.PROPERTY_CATEGORY, "Advanced"), }; + ShowParameterWindow processor = ExtraDesignClassManager.getInstance().getSingle(ShowParameterWindow.MARK_STRING); + if (processor == null) { + return propertyTableEditor; + } + PropertyDescriptor[] extraEditor = processor.add(this.data.getClass()); + + return (CRPropertyDescriptor[]) ArrayUtils.addAll(propertyTableEditor, extraEditor); } @Override From 373b724b76f5a325f38b2a1d8b0b683c442ff481 Mon Sep 17 00:00:00 2001 From: zpc Date: Mon, 25 Jul 2016 14:48:58 +0800 Subject: [PATCH 4/6] =?UTF-8?q?=E4=BB=96=E8=A3=85=E4=BA=86=E6=8F=92?= =?UTF-8?q?=E4=BB=B6=E5=90=8E,=20=E5=8F=AF=E4=BB=A5=E8=AE=BE=E7=BD=AE?= =?UTF-8?q?=E6=98=BE=E7=A4=BA=E6=88=96=E8=80=85=E4=B8=8D=E6=98=BE=E7=A4=BA?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 他装了插件后, 可以设置显示或者不显示 --- ...terWindow.java => ParameterWindowEditorProcessor.java} | 4 ++-- ...r.java => AbstractParameterWindowEditorProcessor.java} | 8 ++++---- .../com/fr/design/designer/creator/XWParameterLayout.java | 6 +++--- 3 files changed, 9 insertions(+), 9 deletions(-) rename designer_base/src/com/fr/design/fun/{ShowParameterWindow.java => ParameterWindowEditorProcessor.java} (66%) rename designer_base/src/com/fr/design/fun/impl/{AbstractShowParameterWindowProvider.java => AbstractParameterWindowEditorProcessor.java} (55%) diff --git a/designer_base/src/com/fr/design/fun/ShowParameterWindow.java b/designer_base/src/com/fr/design/fun/ParameterWindowEditorProcessor.java similarity index 66% rename from designer_base/src/com/fr/design/fun/ShowParameterWindow.java rename to designer_base/src/com/fr/design/fun/ParameterWindowEditorProcessor.java index c8cacb1f0..6d8b6a33f 100644 --- a/designer_base/src/com/fr/design/fun/ShowParameterWindow.java +++ b/designer_base/src/com/fr/design/fun/ParameterWindowEditorProcessor.java @@ -7,7 +7,7 @@ import java.beans.PropertyDescriptor; /** * Created by zpc on 16/7/21. */ -public interface ShowParameterWindow extends Immutable { +public interface ParameterWindowEditorProcessor extends Immutable { String MARK_STRING = "ShowParameter"; @@ -16,6 +16,6 @@ public interface ShowParameterWindow extends Immutable { /** * 生成属性表 */ - PropertyDescriptor[] add(Class temp); + PropertyDescriptor[] createPropertyDescriptor(Class temp); } diff --git a/designer_base/src/com/fr/design/fun/impl/AbstractShowParameterWindowProvider.java b/designer_base/src/com/fr/design/fun/impl/AbstractParameterWindowEditorProcessor.java similarity index 55% rename from designer_base/src/com/fr/design/fun/impl/AbstractShowParameterWindowProvider.java rename to designer_base/src/com/fr/design/fun/impl/AbstractParameterWindowEditorProcessor.java index 6eec6e54b..57375903d 100644 --- a/designer_base/src/com/fr/design/fun/impl/AbstractShowParameterWindowProvider.java +++ b/designer_base/src/com/fr/design/fun/impl/AbstractParameterWindowEditorProcessor.java @@ -1,6 +1,6 @@ package com.fr.design.fun.impl; -import com.fr.design.fun.ShowParameterWindow; +import com.fr.design.fun.ParameterWindowEditorProcessor; import com.fr.stable.fun.mark.API; import java.beans.PropertyDescriptor; @@ -8,8 +8,8 @@ import java.beans.PropertyDescriptor; /** * Created by zpc on 2016/7/21. */ -@API(level = ShowParameterWindow.CURRENT_LEVEL) -public abstract class AbstractShowParameterWindowProvider implements ShowParameterWindow { +@API(level = ParameterWindowEditorProcessor.CURRENT_LEVEL) +public abstract class AbstractParameterWindowEditorProcessor implements ParameterWindowEditorProcessor { public int currentAPILevel() { return CURRENT_LEVEL; @@ -25,7 +25,7 @@ public abstract class AbstractShowParameterWindowProvider implements ShowParamet * 生成属性表 */ @Override - public PropertyDescriptor[] add(Class temp) { + public PropertyDescriptor[] createPropertyDescriptor(Class temp) { return null; } } \ No newline at end of file diff --git a/designer_form/src/com/fr/design/designer/creator/XWParameterLayout.java b/designer_form/src/com/fr/design/designer/creator/XWParameterLayout.java index 58e9dd455..6f13b32b7 100644 --- a/designer_form/src/com/fr/design/designer/creator/XWParameterLayout.java +++ b/designer_form/src/com/fr/design/designer/creator/XWParameterLayout.java @@ -17,7 +17,7 @@ import com.fr.form.ui.container.WFitLayout; import com.fr.form.ui.container.WParameterLayout; import com.fr.general.Background; import com.fr.general.Inter; -import com.fr.design.fun.ShowParameterWindow; +import com.fr.design.fun.ParameterWindowEditorProcessor; import com.fr.stable.ArrayUtils; import java.awt.*; @@ -69,11 +69,11 @@ public class XWParameterLayout extends XWAbsoluteLayout { .putKeyValue(XCreatorConstants.PROPERTY_CATEGORY, "Advanced"), }; - ShowParameterWindow processor = ExtraDesignClassManager.getInstance().getSingle(ShowParameterWindow.MARK_STRING); + ParameterWindowEditorProcessor processor = ExtraDesignClassManager.getInstance().getSingle(ParameterWindowEditorProcessor.MARK_STRING); if (processor == null) { return propertyTableEditor; } - PropertyDescriptor[] extraEditor = processor.add(this.data.getClass()); + PropertyDescriptor[] extraEditor = processor.createPropertyDescriptor(this.data.getClass()); return (CRPropertyDescriptor[]) ArrayUtils.addAll(propertyTableEditor, extraEditor); } From e3be3575eeb68ed6d92f16b788ba83655f1fb19d Mon Sep 17 00:00:00 2001 From: zpc Date: Mon, 25 Jul 2016 15:33:31 +0800 Subject: [PATCH 5/6] =?UTF-8?q?=E4=BF=AE=E6=94=B9=E4=B8=80=E4=BA=9B?= =?UTF-8?q?=E8=A7=84=E8=8C=83=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 修改一些规范问题 --- .../fr/design/report/freeze/RepeatAndFreezeSettingPane.java | 5 ++++- .../com/fr/design/fun/ParameterWindowEditorProcessor.java | 2 +- .../fun/impl/AbstractParameterWindowEditorProcessor.java | 2 +- .../src/com/fr/design/mainframe/toolbar/ToolBarMenuDock.java | 1 - 4 files changed, 6 insertions(+), 4 deletions(-) diff --git a/designer/src/com/fr/design/report/freeze/RepeatAndFreezeSettingPane.java b/designer/src/com/fr/design/report/freeze/RepeatAndFreezeSettingPane.java index 3fa4d349a..7cf176302 100644 --- a/designer/src/com/fr/design/report/freeze/RepeatAndFreezeSettingPane.java +++ b/designer/src/com/fr/design/report/freeze/RepeatAndFreezeSettingPane.java @@ -28,6 +28,10 @@ import com.fr.stable.bridge.StableFactory; * Sets Report Page Attributes */ public class RepeatAndFreezeSettingPane extends BasicPane { + + //边框高度 + private static final int LABEL_HEIGHT = 45; + // 重复标题行 private RepeatRowPane repeatTitleRowPane; // 重复标题列 @@ -57,7 +61,6 @@ public class RepeatAndFreezeSettingPane extends BasicPane { // 填报冻结 private UICheckBox useWriteFrozenCCheckBox; private UICheckBox useWriteFrozenRCheckBox; - private static final int LABEL_HEIGHT = 45; /** * 重复标题行 diff --git a/designer_base/src/com/fr/design/fun/ParameterWindowEditorProcessor.java b/designer_base/src/com/fr/design/fun/ParameterWindowEditorProcessor.java index 6d8b6a33f..869556065 100644 --- a/designer_base/src/com/fr/design/fun/ParameterWindowEditorProcessor.java +++ b/designer_base/src/com/fr/design/fun/ParameterWindowEditorProcessor.java @@ -9,7 +9,7 @@ import java.beans.PropertyDescriptor; */ public interface ParameterWindowEditorProcessor extends Immutable { - String MARK_STRING = "ShowParameter"; + String MARK_STRING = "ParameterWindowEditorProcessor"; int CURRENT_LEVEL = 1; diff --git a/designer_base/src/com/fr/design/fun/impl/AbstractParameterWindowEditorProcessor.java b/designer_base/src/com/fr/design/fun/impl/AbstractParameterWindowEditorProcessor.java index 57375903d..fcdd432b2 100644 --- a/designer_base/src/com/fr/design/fun/impl/AbstractParameterWindowEditorProcessor.java +++ b/designer_base/src/com/fr/design/fun/impl/AbstractParameterWindowEditorProcessor.java @@ -26,6 +26,6 @@ public abstract class AbstractParameterWindowEditorProcessor implements Paramete */ @Override public PropertyDescriptor[] createPropertyDescriptor(Class temp) { - return null; + return new PropertyDescriptor[0]; } } \ No newline at end of file diff --git a/designer_base/src/com/fr/design/mainframe/toolbar/ToolBarMenuDock.java b/designer_base/src/com/fr/design/mainframe/toolbar/ToolBarMenuDock.java index 364a11cee..d0177d404 100644 --- a/designer_base/src/com/fr/design/mainframe/toolbar/ToolBarMenuDock.java +++ b/designer_base/src/com/fr/design/mainframe/toolbar/ToolBarMenuDock.java @@ -301,7 +301,6 @@ public abstract class ToolBarMenuDock { if (ComparatorUtils.equals(ProductConstants.APP_NAME,FINEREPORT)) { shortCuts.add(new FeedBackAction()); shortCuts.add(SeparatorDef.DEFAULT); - //shortCuts.add(new SupportQQAction()); shortCuts.add(SeparatorDef.DEFAULT); // shortCuts.add(new ForumAction()); } From 181473e663020e1bb4ac35a507a0665cfac749d4 Mon Sep 17 00:00:00 2001 From: zpc Date: Mon, 25 Jul 2016 17:48:01 +0800 Subject: [PATCH 6/6] =?UTF-8?q?=E4=BB=A3=E7=A0=81=E8=A7=84=E8=8C=83?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 代码规范 --- .../fr/design/report/freeze/RepeatAndFreezeSettingPane.java | 2 +- .../fr/design/designer/creator/CRPropertyDescriptor.java | 4 ++-- .../com/fr/design/fun/ParameterWindowEditorProcessor.java | 5 ++--- .../fun/impl/AbstractParameterWindowEditorProcessor.java | 6 +++--- .../com/fr/design/designer/creator/XWParameterLayout.java | 4 ++-- 5 files changed, 10 insertions(+), 11 deletions(-) rename {designer_form => designer_base}/src/com/fr/design/designer/creator/CRPropertyDescriptor.java (92%) diff --git a/designer/src/com/fr/design/report/freeze/RepeatAndFreezeSettingPane.java b/designer/src/com/fr/design/report/freeze/RepeatAndFreezeSettingPane.java index 7cf176302..fd24573fe 100644 --- a/designer/src/com/fr/design/report/freeze/RepeatAndFreezeSettingPane.java +++ b/designer/src/com/fr/design/report/freeze/RepeatAndFreezeSettingPane.java @@ -218,7 +218,7 @@ public class RepeatAndFreezeSettingPane extends BasicPane { JPanel freezePanel = FRGUIPaneFactory.createBorderLayout_S_Pane(); //自适应插件 - JPanel infoPane = FRGUIPaneFactory.createTitledBorderPane(Inter.getLocText("Attention")); + JPanel infoPane = FRGUIPaneFactory.createTitledBorderPane(Inter.getLocText("FR-Designer_Attention")); BoxCenterAligmentPane actionLabel = getURLActionLabel(Inter.getLocText("FR-Designer_Form-Fit-Tip")); infoPane.add(actionLabel, BorderLayout.SOUTH); diff --git a/designer_form/src/com/fr/design/designer/creator/CRPropertyDescriptor.java b/designer_base/src/com/fr/design/designer/creator/CRPropertyDescriptor.java similarity index 92% rename from designer_form/src/com/fr/design/designer/creator/CRPropertyDescriptor.java rename to designer_base/src/com/fr/design/designer/creator/CRPropertyDescriptor.java index c56e150c0..315565324 100644 --- a/designer_form/src/com/fr/design/designer/creator/CRPropertyDescriptor.java +++ b/designer_base/src/com/fr/design/designer/creator/CRPropertyDescriptor.java @@ -3,7 +3,6 @@ */ package com.fr.design.designer.creator; -import com.fr.design.gui.xtable.AbstractPropertyGroupModel; import com.fr.stable.StringUtils; import com.fr.stable.core.PropertyChangeAdapter; @@ -15,6 +14,7 @@ import java.beans.PropertyDescriptor; * @since 6.5.3 */ public final class CRPropertyDescriptor extends PropertyDescriptor { + public static final String RENDERER = "renderer"; private PropertyChangeAdapter l; @@ -51,7 +51,7 @@ public final class CRPropertyDescriptor extends PropertyDescriptor { } public CRPropertyDescriptor setRendererClass(Class clazz) { - this.putKeyValue(AbstractPropertyGroupModel.RENDERER, clazz); + this.putKeyValue(RENDERER, clazz); return this; } diff --git a/designer_base/src/com/fr/design/fun/ParameterWindowEditorProcessor.java b/designer_base/src/com/fr/design/fun/ParameterWindowEditorProcessor.java index 869556065..d1eb60a88 100644 --- a/designer_base/src/com/fr/design/fun/ParameterWindowEditorProcessor.java +++ b/designer_base/src/com/fr/design/fun/ParameterWindowEditorProcessor.java @@ -1,8 +1,7 @@ package com.fr.design.fun; +import com.fr.design.designer.creator.CRPropertyDescriptor; import com.fr.stable.fun.mark.Immutable; -import java.beans.PropertyDescriptor; - /** * Created by zpc on 16/7/21. @@ -16,6 +15,6 @@ public interface ParameterWindowEditorProcessor extends Immutable { /** * 生成属性表 */ - PropertyDescriptor[] createPropertyDescriptor(Class temp); + CRPropertyDescriptor[] createPropertyDescriptor(Class temp); } diff --git a/designer_base/src/com/fr/design/fun/impl/AbstractParameterWindowEditorProcessor.java b/designer_base/src/com/fr/design/fun/impl/AbstractParameterWindowEditorProcessor.java index fcdd432b2..0d449090f 100644 --- a/designer_base/src/com/fr/design/fun/impl/AbstractParameterWindowEditorProcessor.java +++ b/designer_base/src/com/fr/design/fun/impl/AbstractParameterWindowEditorProcessor.java @@ -1,8 +1,8 @@ package com.fr.design.fun.impl; +import com.fr.design.designer.creator.CRPropertyDescriptor; import com.fr.design.fun.ParameterWindowEditorProcessor; import com.fr.stable.fun.mark.API; -import java.beans.PropertyDescriptor; /** @@ -25,7 +25,7 @@ public abstract class AbstractParameterWindowEditorProcessor implements Paramete * 生成属性表 */ @Override - public PropertyDescriptor[] createPropertyDescriptor(Class temp) { - return new PropertyDescriptor[0]; + public CRPropertyDescriptor[] createPropertyDescriptor(Class temp) { + return new CRPropertyDescriptor[0]; } } \ No newline at end of file diff --git a/designer_form/src/com/fr/design/designer/creator/XWParameterLayout.java b/designer_form/src/com/fr/design/designer/creator/XWParameterLayout.java index 6f13b32b7..9e5520716 100644 --- a/designer_form/src/com/fr/design/designer/creator/XWParameterLayout.java +++ b/designer_form/src/com/fr/design/designer/creator/XWParameterLayout.java @@ -73,9 +73,9 @@ public class XWParameterLayout extends XWAbsoluteLayout { if (processor == null) { return propertyTableEditor; } - PropertyDescriptor[] extraEditor = processor.createPropertyDescriptor(this.data.getClass()); + CRPropertyDescriptor[] extraEditor = processor.createPropertyDescriptor(this.data.getClass()); - return (CRPropertyDescriptor[]) ArrayUtils.addAll(propertyTableEditor, extraEditor); + return ArrayUtils.addAll(propertyTableEditor, extraEditor); } @Override