Browse Source

Merge branch 'release/10.0' of http://cloud.finedevelop.com:2015/scm/~mata.li/designrel into release/10.0

final/10.0
Mata.Li 7 years ago
parent
commit
99b825332b
  1. 14
      designer-chart/src/main/java/com/fr/design/ChartTypeInterfaceManager.java
  2. 3
      designer-form/src/main/java/com/fr/design/mainframe/widget/ui/FormWidgetCardPane.java
  3. 11
      designer-form/src/main/java/com/fr/design/widget/ui/designer/layout/FRAbsoluteBodyLayoutDefinePane.java
  4. 18
      designer-form/src/main/java/com/fr/design/widget/ui/designer/layout/FRAbsoluteLayoutDefinePane.java
  5. 6
      designer-realize/src/main/java/com/fr/design/mainframe/alphafine/search/manager/impl/RecentSearchManager.java
  6. 30
      designer-realize/src/main/java/com/fr/design/mainframe/bbs/UserInfoPane.java
  7. 2
      designer-realize/src/main/java/com/fr/start/module/DesignerActivator.java

14
designer-chart/src/main/java/com/fr/design/ChartTypeInterfaceManager.java

@ -137,13 +137,13 @@ public class ChartTypeInterfaceManager implements ExtraChartDesignClassManagerPr
}
//异步加载图片
new Thread(new Runnable() {
@Override
public void run() {
initAllChartsDemoImage(allCharts);
}
}).start();
// new Thread(new Runnable() {
//
// @Override
// public void run() {
// initAllChartsDemoImage(allCharts);
// }
// }).start();
return child;
}

3
designer-form/src/main/java/com/fr/design/mainframe/widget/ui/FormWidgetCardPane.java

@ -6,6 +6,7 @@ import com.fr.design.designer.beans.events.DesignerEvent;
import com.fr.design.designer.creator.XCreator;
import com.fr.design.designer.creator.XCreatorUtils;
import com.fr.design.designer.creator.XLayoutContainer;
import com.fr.design.designer.creator.XWAbsoluteBodyLayout;
import com.fr.design.designer.creator.XWAbsoluteLayout;
import com.fr.design.designer.creator.XWFitLayout;
import com.fr.design.designer.creator.XWParameterLayout;
@ -79,7 +80,7 @@ public class FormWidgetCardPane extends AbstractAttrNoScrollPane {
public WidgetBoundPane createWidgetBoundPane(XCreator xCreator) {
XLayoutContainer xLayoutContainer = getParent(xCreator);
if (xLayoutContainer == null || xCreator.acceptType(XWParameterLayout.class) || xCreator.acceptType(XWAbsoluteLayout.class)) {
if (xLayoutContainer == null || xCreator.acceptType(XWParameterLayout.class) || xCreator.acceptType(XWAbsoluteBodyLayout.class)) {
return null;
} else if (xLayoutContainer.acceptType(XWAbsoluteLayout.class)) {
return new WidgetAbsoluteBoundPane(xCreator);

11
designer-form/src/main/java/com/fr/design/widget/ui/designer/layout/FRAbsoluteBodyLayoutDefinePane.java

@ -19,6 +19,7 @@ import com.fr.design.mainframe.FormDesigner;
import com.fr.design.mainframe.WidgetPropertyPane;
import com.fr.design.mainframe.widget.accessibles.AccessibleBodyWatermarkEditor;
import com.fr.design.mainframe.widget.accessibles.AccessibleWLayoutBorderStyleEditor;
import com.fr.design.widget.ui.designer.component.WidgetBoundPane;
import com.fr.form.ui.LayoutBorderStyle;
import com.fr.form.ui.container.WAbsoluteBodyLayout;
import com.fr.form.ui.container.WAbsoluteLayout;
@ -43,6 +44,7 @@ public class FRAbsoluteBodyLayoutDefinePane extends FRAbsoluteLayoutDefinePane {
private AccessibleWLayoutBorderStyleEditor borderStyleEditor;
private AccessibleBodyWatermarkEditor watermarkEditor;
private WidgetBoundPane boundPane;
private UIComboBox layoutCombox;
private WBodyLayoutType layoutType = WBodyLayoutType.ABSOLUTE;
@ -54,6 +56,9 @@ public class FRAbsoluteBodyLayoutDefinePane extends FRAbsoluteLayoutDefinePane {
public void initComponent() {
super.initComponent();
JPanel centerPane = FRGUIPaneFactory.createBorderLayout_S_Pane();
boundPane = new WidgetBoundPane(creator);
centerPane.add(boundPane, BorderLayout.CENTER);
borderStyleEditor = new AccessibleWLayoutBorderStyleEditor();
watermarkEditor = new AccessibleBodyWatermarkEditor();
JPanel jPanel = TableLayoutHelper.createGapTableLayoutPane(
@ -65,7 +70,8 @@ public class FRAbsoluteBodyLayoutDefinePane extends FRAbsoluteLayoutDefinePane {
jPanel.setBorder(BorderFactory.createEmptyBorder(10, 0, 10, 0));
borderPane.add(jPanel, BorderLayout.CENTER);
UIExpandablePane advancedPane = new UIExpandablePane(com.fr.design.i18n.Toolkit.i18nText("FR-Designer_Advanced"), 280, 20, borderPane );
this.add(advancedPane, BorderLayout.NORTH);
centerPane.add(advancedPane, BorderLayout.NORTH);
this.add(centerPane, BorderLayout.NORTH);
}
public JPanel createThirdPane() {
@ -77,7 +83,6 @@ public class FRAbsoluteBodyLayoutDefinePane extends FRAbsoluteLayoutDefinePane {
new Component[]{new UILabel(com.fr.design.i18n.Toolkit.i18nText("FR-Designer-Widget_Scaling_Mode")), comboBox}}, TableLayoutHelper.FILL_LASTCOLUMN, IntervalConstants.INTERVAL_W1, IntervalConstants.INTERVAL_L1);
jPanel.add(northPane, BorderLayout.NORTH);
jPanel.add(centerPane, BorderLayout.CENTER);
// northPane.setBorder(BorderFactory.createEmptyBorder(IntervalConstants.INTERVAL_L1, 0, 0, 0));
centerPane.setBorder(BorderFactory.createEmptyBorder(IntervalConstants.INTERVAL_L1, IntervalConstants.INTERVAL_L5, 0, 0));
return jPanel;
@ -101,12 +106,14 @@ public class FRAbsoluteBodyLayoutDefinePane extends FRAbsoluteLayoutDefinePane {
public void populateSubPane(WAbsoluteLayout ob) {
layoutCombox.setSelectedIndex(1);
borderStyleEditor.setValue(ob.getBorderStyle());
boundPane.populate();
watermarkEditor.setValue(ReportUtils.getWatermarkFromAttrMarkFile(getCurrentIOFile()));
}
public WAbsoluteBodyLayout updateSubPane() {
WAbsoluteBodyLayout layout = (WAbsoluteBodyLayout) creator.toData();
boundPane.update();
Item item = (Item) layoutCombox.getSelectedItem();
Object value = item.getValue();
int state = 0;

18
designer-form/src/main/java/com/fr/design/widget/ui/designer/layout/FRAbsoluteLayoutDefinePane.java

@ -12,19 +12,19 @@ import com.fr.design.layout.FRGUIPaneFactory;
import com.fr.design.layout.TableLayout;
import com.fr.design.layout.TableLayoutHelper;
import com.fr.design.widget.ui.designer.AbstractDataModify;
import com.fr.design.widget.ui.designer.component.WidgetBoundPane;
import com.fr.form.ui.container.WAbsoluteLayout;
import javax.swing.*;
import java.awt.*;
import javax.swing.BorderFactory;
import javax.swing.DefaultComboBoxModel;
import javax.swing.JPanel;
import java.awt.BorderLayout;
import java.awt.Component;
/**
* Created by ibm on 2017/8/2.
*/
public class FRAbsoluteLayoutDefinePane extends AbstractDataModify<WAbsoluteLayout> {
protected UIComboBox comboBox;
private WidgetBoundPane boundPane;
public FRAbsoluteLayoutDefinePane(XCreator xCreator) {
super(xCreator);
@ -34,17 +34,13 @@ public class FRAbsoluteLayoutDefinePane extends AbstractDataModify<WAbsoluteLayo
public void initComponent() {
this.setLayout(FRGUIPaneFactory.createBorderLayout());
JPanel centerPane = FRGUIPaneFactory.createBorderLayout_S_Pane();
boundPane = new WidgetBoundPane(creator);
centerPane.add(boundPane, BorderLayout.NORTH);
initUIComboBox();
JPanel thirdPane = FRGUIPaneFactory.createBorderLayout_S_Pane();
JPanel jPanel = createThirdPane();
jPanel.setBorder(BorderFactory.createEmptyBorder(10, 0, 10, 0));
thirdPane.add(jPanel, BorderLayout.CENTER);
UIExpandablePane layoutExpandablePane = new UIExpandablePane(com.fr.design.i18n.Toolkit.i18nText("FR-Designer-Widget_Area_Scaling"), 280, 20, thirdPane);
centerPane.add(layoutExpandablePane, BorderLayout.CENTER);
this.add(centerPane, BorderLayout.CENTER);
this.add(layoutExpandablePane, BorderLayout.CENTER);
}
public JPanel createThirdPane() {
@ -80,7 +76,6 @@ public class FRAbsoluteLayoutDefinePane extends AbstractDataModify<WAbsoluteLayo
public void populateBean(WAbsoluteLayout ob) {
populateSubPane(ob);
comboBox.setSelectedIndex(ob.getCompState());
boundPane.populate();
}
@ -88,7 +83,6 @@ public class FRAbsoluteLayoutDefinePane extends AbstractDataModify<WAbsoluteLayo
public WAbsoluteLayout updateBean() {
WAbsoluteLayout wAbsoluteLayout = updateSubPane();
wAbsoluteLayout.setCompState(comboBox.getSelectedIndex());
boundPane.update();
return wAbsoluteLayout;
}

6
designer-realize/src/main/java/com/fr/design/mainframe/alphafine/search/manager/impl/RecentSearchManager.java

@ -77,8 +77,12 @@ public class RecentSearchManager implements AlphaFineSearchProvider {
recentModelList = getRecentModelList(searchText);
if (recentModelList != null && recentModelList.size() > 0) {
modelList.add(new MoreModel(com.fr.design.i18n.Toolkit.i18nText("FR-Designer_AlphaFine_Latest")));
if (recentModelList.size() > AlphaFineConstants.LATEST_SHOW_SIZE) {
modelList.addAll(recentModelList.subList(0, AlphaFineConstants.LATEST_SHOW_SIZE));
} else {
modelList.addAll(recentModelList);
}
}
modelList.addAll(recentModelList.subList(0, AlphaFineConstants.LATEST_SHOW_SIZE));
return modelList;
}

30
designer-realize/src/main/java/com/fr/design/mainframe/bbs/UserInfoPane.java

@ -4,18 +4,14 @@
package com.fr.design.mainframe.bbs;
import com.fr.base.FRContext;
import com.fr.config.BaseDBEnv;
import com.fr.config.MarketConfig;
import com.fr.design.DesignerEnvManager;
import com.fr.design.constants.UIConstants;
import com.fr.design.dialog.BasicPane;
import com.fr.design.mainframe.DesignerContext;
import com.fr.general.DateUtils;
import com.fr.general.GeneralContext;
import com.fr.stable.EnvChangedListener;
import com.fr.log.FineLoggerFactory;
import com.fr.stable.StringUtils;
import java.awt.BorderLayout;
import java.awt.Color;
import java.awt.Dimension;
@ -73,7 +69,6 @@ public class UserInfoPane extends BasicPane {
this.userInfoLabel = new UserInfoLabel(this);
this.markUnSignIn();
addEnvChangedListener();
autoPushLoginDialog();
this.add(userInfoLabel, BorderLayout.CENTER);
@ -115,20 +110,13 @@ public class UserInfoPane extends BasicPane {
return StringUtils.EMPTY;
}
private void addEnvChangedListener() {
GeneralContext.addEnvChangedListener(new EnvChangedListener() {
@Override
public void envChanged() {
if (BaseDBEnv.isDBEnvAvailable()) {
String username = MarketConfig.getInstance().getBbsUsername();
if (StringUtils.isEmpty(username)) {
markUnSignIn();
} else {
markSignIn(username);
}
}
}
});
public void updateBBSUserInfo(){
String username = MarketConfig.getInstance().getBbsUsername();
if (StringUtils.isEmpty(username)) {
markUnSignIn();
} else {
markSignIn(username);
}
}
@ -154,7 +142,7 @@ public class UserInfoPane extends BasicPane {
return dayNew - dayOld;
}
} catch (ParseException e) {
FRContext.getLogger().error(e.getMessage());
FineLoggerFactory.getLogger().error(e.getMessage());
}
return 1;
}

2
designer-realize/src/main/java/com/fr/start/module/DesignerActivator.java

@ -43,6 +43,7 @@ import com.fr.design.mainframe.WidgetPropertyPane;
import com.fr.design.mainframe.WidgetToolBarPane;
import com.fr.design.mainframe.actions.NewFormAction;
import com.fr.design.mainframe.bbs.BBSGuestPane;
import com.fr.design.mainframe.bbs.UserInfoPane;
import com.fr.design.mainframe.form.FormECCompositeProvider;
import com.fr.design.mainframe.form.FormECDesignerProvider;
import com.fr.design.mainframe.form.FormElementCaseDesigner;
@ -123,6 +124,7 @@ public class DesignerActivator extends Activator implements Prepare {
preLoadPane();
loadLogAppender();
DesignerSocketIO.update();
UserInfoPane.getInstance().updateBBSUserInfo();
}
private void loadLogAppender() {

Loading…
Cancel
Save