|
|
@ -44,9 +44,15 @@ import com.fr.esd.event.DsNameTarget; |
|
|
|
import com.fr.esd.event.StrategyEventsNotifier; |
|
|
|
import com.fr.esd.event.StrategyEventsNotifier; |
|
|
|
import com.fr.esd.query.StrategicTableData; |
|
|
|
import com.fr.esd.query.StrategicTableData; |
|
|
|
import com.fr.general.ComparatorUtils; |
|
|
|
import com.fr.general.ComparatorUtils; |
|
|
|
|
|
|
|
import com.fr.general.GeneralContext; |
|
|
|
import com.fr.general.IOUtils; |
|
|
|
import com.fr.general.IOUtils; |
|
|
|
import com.fr.general.NameObject; |
|
|
|
import com.fr.general.NameObject; |
|
|
|
import com.fr.log.FineLoggerFactory; |
|
|
|
import com.fr.log.FineLoggerFactory; |
|
|
|
|
|
|
|
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.stable.core.PropertyChangeAdapter; |
|
|
|
import com.fr.stable.core.PropertyChangeAdapter; |
|
|
|
import org.jetbrains.annotations.NotNull; |
|
|
|
import org.jetbrains.annotations.NotNull; |
|
|
|
|
|
|
|
|
|
|
@ -120,6 +126,8 @@ public class TableDataTreePane extends BasicTableDataTreePane { |
|
|
|
addMenuDef = new MenuDef(Toolkit.i18nText("Fine-Design_Basic_Action_Add")); |
|
|
|
addMenuDef = new MenuDef(Toolkit.i18nText("Fine-Design_Basic_Action_Add")); |
|
|
|
addMenuDef.setIconPath(IconPathConstants.ADD_POPMENU_ICON_PATH); |
|
|
|
addMenuDef.setIconPath(IconPathConstants.ADD_POPMENU_ICON_PATH); |
|
|
|
createAddMenuDef(); |
|
|
|
createAddMenuDef(); |
|
|
|
|
|
|
|
// 创建插件监听
|
|
|
|
|
|
|
|
createPluginListener(); |
|
|
|
|
|
|
|
|
|
|
|
editAction = new EditAction(); |
|
|
|
editAction = new EditAction(); |
|
|
|
removeAction = new RemoveAction(); |
|
|
|
removeAction = new RemoveAction(); |
|
|
@ -165,6 +173,26 @@ public class TableDataTreePane extends BasicTableDataTreePane { |
|
|
|
checkButtonEnabled(); |
|
|
|
checkButtonEnabled(); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
private void createPluginListener() { |
|
|
|
|
|
|
|
//菜单栏监听
|
|
|
|
|
|
|
|
GeneralContext.listenPluginRunningChanged(new PluginEventListener(PLUGIN_LISTENER_PRIORITY) { |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
@Override |
|
|
|
|
|
|
|
public void on(PluginEvent event) { |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
addMenuDef.clearShortCuts(); |
|
|
|
|
|
|
|
createAddMenuDef(); |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
}, new PluginFilter() { |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
@Override |
|
|
|
|
|
|
|
public boolean accept(PluginContext context) { |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
return context.contain(PluginModule.ExtraDesign); |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
}); |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
/** |
|
|
|
/** |
|
|
|
* 刷新 |
|
|
|
* 刷新 |
|
|
|
*/ |
|
|
|
*/ |
|
|
|