Browse Source

Merge branch 'release/10.0' of https://cloud.finedevelop.com/scm/~hades/design into release/10.0

bugfix/10.0
Hades 6 years ago
parent
commit
075397cdc8
  1. 6
      designer-base/src/main/java/com/fr/design/actions/file/PreferenceAction.java
  2. 10
      designer-base/src/main/java/com/fr/design/gui/itree/filetree/TemplateFileTree.java
  3. 9
      designer-base/src/main/java/com/fr/design/mainframe/mobile/ui/DownMenuStyleDefinePane.java
  4. 2
      designer-base/src/main/java/com/fr/design/mainframe/vcs/common/VcsHelper.java
  5. 5
      designer-realize/src/main/java/com/fr/design/mainframe/messagecollect/entity/FileEntityBuilder.java

6
designer-base/src/main/java/com/fr/design/actions/file/PreferenceAction.java

@ -4,9 +4,10 @@ import com.fr.design.DesignerEnvManager;
import com.fr.design.actions.UpdateAction;
import com.fr.design.dialog.BasicDialog;
import com.fr.design.dialog.DialogActionAdapter;
import com.fr.design.file.HistoryTemplateListPane;
import com.fr.design.file.HistoryTemplateListCache;
import com.fr.design.mainframe.DesignerContext;
import com.fr.design.mainframe.DesignerFrame;
import com.fr.design.mainframe.DesignerFrameFileDealerPane;
import com.fr.design.mainframe.JTemplate;
import com.fr.design.menu.KeySetUtils;
@ -38,9 +39,10 @@ public class PreferenceAction extends UpdateAction {
preferencePane.update(DesignerEnvManager.getEnvManager());
DesignerEnvManager.loadLogSetting();
DesignerEnvManager.getEnvManager().saveXMLFile();
JTemplate jt = HistoryTemplateListPane.getInstance().getCurrentEditingTemplate();
JTemplate jt = HistoryTemplateListCache.getInstance().getCurrentEditingTemplate();
jt.refreshToolArea();
preferencePane.showRestartDialog();
DesignerFrameFileDealerPane.getInstance().refreshDockingView();
}
});

10
designer-base/src/main/java/com/fr/design/gui/itree/filetree/TemplateFileTree.java

@ -228,16 +228,6 @@ public class TemplateFileTree extends EnvFileTree {
if (fileNodes == null) {
fileNodes = new FileNode[0];
}
// FileNodeFilter过滤
if (filter != null) {
List<FileNode> list = new ArrayList<FileNode>();
for (FileNode fileNode : fileNodes) {
if (filter.accept(fileNode)) {
list.add(fileNode);
}
}
fileNodes = list.toArray(new FileNode[list.size()]);
}
Arrays.sort(fileNodes, new FileNodeComparator(FRContext.getFileNodes().getSupportedTypes()));
return fileNodes;

9
designer-base/src/main/java/com/fr/design/mainframe/mobile/ui/DownMenuStyleDefinePane.java

@ -2,7 +2,6 @@ package com.fr.design.mainframe.mobile.ui;
import com.fr.base.GraphHelper;
import com.fr.base.Icon;
import com.fr.base.IconManager;
import com.fr.design.constants.LayoutConstants;
import com.fr.design.designer.IntervalConstants;
import com.fr.design.gui.ilable.UILabel;
@ -11,6 +10,7 @@ import com.fr.design.layout.TableLayoutHelper;
import com.fr.design.mainframe.widget.UITitleSplitLine;
import com.fr.design.mainframe.widget.preview.MobileTemplatePreviewPane;
import com.fr.form.ui.CardSwitchButton;
import com.fr.form.ui.WidgetInfoConfig;
import com.fr.form.ui.container.cardlayout.WCardTagLayout;
import com.fr.general.FRFont;
import com.fr.general.cardtag.mobile.DownMenuStyle;
@ -40,6 +40,7 @@ public class DownMenuStyleDefinePane extends StyleDefinePaneWithSelectConf {
super(tagLayout);
}
@Override
protected void createExtraConfPane(JPanel centerPane) {
JPanel panel = FRGUIPaneFactory.createVerticalFlowLayout_Pane(true, FlowLayout.LEADING, 0, 0);
panel.setBorder(BorderFactory.createEmptyBorder(0, 20, 5, 20));
@ -134,12 +135,13 @@ public class DownMenuStyleDefinePane extends StyleDefinePaneWithSelectConf {
private static final int GAP = 6;
private static final String PAINT_ICON = "fund_white";
private static final String ICON_PATH = "/com/fr/web/images/fund_white.png";
private LineDescription splitLine;
private transient LineDescription splitLine;
public DownMenuStylePreviewPane() {
this.setBackground(Color.decode("#3888EE"));
}
@Override
public void repaint() {
super.repaint();
}
@ -172,7 +174,7 @@ public class DownMenuStyleDefinePane extends StyleDefinePaneWithSelectConf {
g2d.setColor(oldColor);
}
Icon icon = new Icon(PAINT_ICON, ICON_PATH);
g2d.drawImage(IconManager.getIconManager().getDefaultIconImage(icon), (eachWidth - ICON_OFFSET) / 2, (panelHeight - ICON_OFFSET - GAP - fontHeight) / 2, null);
g2d.drawImage(WidgetInfoConfig.getInstance().getIconManager().getDefaultIconImage(icon), (eachWidth - ICON_OFFSET) / 2, (panelHeight - ICON_OFFSET - GAP - fontHeight) / 2, null);
g2d.drawString(displayName, (eachWidth - width) / 2, (panelHeight + ICON_OFFSET + GAP - fontHeight) / 2 + ascent);
Stroke oldStroke = g2d.getStroke();
if (splitLine.getLineStyle() != 0) {
@ -187,6 +189,7 @@ public class DownMenuStyleDefinePane extends StyleDefinePaneWithSelectConf {
}
@Override
public void populateConfig(MobileTemplateStyle templateStyle) {
super.populateConfig(templateStyle);
this.splitLine = ((DownMenuStyle) templateStyle).getSplitLine();

2
designer-base/src/main/java/com/fr/design/mainframe/vcs/common/VcsHelper.java

@ -115,7 +115,7 @@ public class VcsHelper implements JTemplateActionListener {
public boolean needInit() {
PluginContext context = PluginManager.getContext(VCS_PLUGIN_ID);
return context == null || !context.isActive();
return context == null || !context.isRunning();
}
/**

5
designer-realize/src/main/java/com/fr/design/mainframe/messagecollect/entity/FileEntityBuilder.java

@ -21,6 +21,7 @@ import java.io.File;
import java.io.FileOutputStream;
import java.io.IOException;
import java.io.InputStream;
import java.net.URLEncoder;
import java.util.HashMap;
import java.util.UUID;
@ -31,7 +32,7 @@ import java.util.UUID;
public class FileEntityBuilder {
private static final String FOCUS_POINT_FILE_ROOT_PATH = "FocusPoint";
private static final String FOCUS_POINT_FILE_UPLOAD_TOPIC = "__fine_intelli_treasure_upload__";
private static final String FOCUS_POINT_FILE_UPLOAD_TOPIC = "__fine_intelli_file_upload__";
private static final String FILE_FROM = "design";
private static final String FOCUS_POINT_FILE_UPLOAD_TYPE = "FocusPoint";
private static final String FOCUS_POINT_FILE_UPLOAD_URL = CloudCenter.getInstance().acquireUrlByKind("design.feedback");
@ -120,7 +121,7 @@ public class FileEntityBuilder {
try {
HashMap<String, Object> params = new HashMap<>();
params.put("topic", FOCUS_POINT_FILE_UPLOAD_TOPIC);
params.put("username", userName);
params.put("username", URLEncoder.encode(userName, EncodeConstants.ENCODING_UTF_8));
params.put("uuid", uuid);
params.put("filepath", filePath);
params.put("timestamp", String.valueOf(System.currentTimeMillis()));

Loading…
Cancel
Save