From e56c707fadbf98b7f8dae822e33046ae836347e5 Mon Sep 17 00:00:00 2001 From: juhaoyu <2335173323@qq.com> Date: Thu, 15 Jun 2017 10:22:19 +0800 Subject: [PATCH] =?UTF-8?q?=E6=8F=92=E4=BB=B6=E6=94=B9=E5=8F=98=E6=97=B6?= =?UTF-8?q?=E5=88=B7=E6=96=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../mainframe/CellElementPropertyPane.java | 32 ++++++++++++++++++- 1 file changed, 31 insertions(+), 1 deletion(-) diff --git a/designer/src/com/fr/design/mainframe/CellElementPropertyPane.java b/designer/src/com/fr/design/mainframe/CellElementPropertyPane.java index 69a68f4515..27e7e22ced 100644 --- a/designer/src/com/fr/design/mainframe/CellElementPropertyPane.java +++ b/designer/src/com/fr/design/mainframe/CellElementPropertyPane.java @@ -12,14 +12,22 @@ import javax.swing.JPanel; import javax.swing.SwingConstants; import com.fr.base.BaseUtils; +import com.fr.design.fun.CellAttributeProvider; +import com.fr.design.fun.PresentKindProvider; import com.fr.design.gui.frpane.UITitlePanel; import com.fr.design.gui.ilable.UILabel; import com.fr.design.gui.itabpane.TitleChangeListener; import com.fr.design.mainframe.cell.CellElementEditPane; +import com.fr.general.GeneralContext; import com.fr.general.Inter; import com.fr.grid.selection.CellSelection; import com.fr.grid.selection.FloatSelection; import com.fr.grid.selection.Selection; +import com.fr.plugin.context.PluginContext; +import com.fr.plugin.injectable.PluginModule; +import com.fr.plugin.manage.PluginFilter; +import com.fr.plugin.observer.PluginEvent; +import com.fr.plugin.observer.PluginEventListener; import com.fr.report.cell.DefaultTemplateCellElement; import com.fr.report.cell.Elem; import com.fr.report.elementcase.TemplateElementCase; @@ -34,7 +42,29 @@ import com.fr.report.elementcase.TemplateElementCase; * @since 2012-5-24下午1:50:21 */ public class CellElementPropertyPane extends DockingView { - + + static { + GeneralContext.listenPluginRunningChanged(new PluginEventListener() { + + @Override + public void on(PluginEvent event) { + + synchronized (CellElementPropertyPane.class) { + singleton = new CellElementPropertyPane(); + } + } + }, new PluginFilter() { + + @Override + public boolean accept(PluginContext context) { + + return context.contain(PluginModule.ExtraDesign, PresentKindProvider.MARK_STRING) || + context.contain(PluginModule.ExtraDesign, CellAttributeProvider.MARK_STRING); + } + }); + } + + public synchronized static CellElementPropertyPane getInstance() { if (singleton == null) { singleton = new CellElementPropertyPane();