Browse Source

Merge branch 'release/10.0' of http://cloud.finedevelop.com:2015/scm/~alex.sung/design into release/10.0

final/10.0
alex.sung 6 years ago
parent
commit
e44f433a4e
  1. 24
      designer-base/src/main/java/com/fr/design/file/MutilTempalteTabPane.java
  2. 11
      designer-base/src/main/java/com/fr/design/remote/ui/AuthorityListControlPane.java
  3. 12
      designer-base/src/main/java/com/fr/design/remote/ui/UserManagerPane.java
  4. BIN
      designer-base/src/main/resources/com/fr/design/images/buttonicon/user_search_normal.png
  5. BIN
      designer-base/src/main/resources/com/fr/design/images/buttonicon/user_search_normal@2x.png
  6. 2
      designer-chart/src/main/java/com/fr/van/chart/designer/component/background/VanChartBackgroundPane.java
  7. 2
      designer-realize/src/main/java/com/fr/design/webattr/printsettings/NativePrintSettingPane.java
  8. 7
      designer-realize/src/main/java/com/fr/start/preload/ImagePreLoader.java

24
designer-base/src/main/java/com/fr/design/file/MutilTempalteTabPane.java

@ -17,6 +17,7 @@ import com.fr.general.ComparatorUtils;
import com.fr.log.FineLoggerFactory;
import com.fr.stable.Constants;
import com.fr.stable.ProductConstants;
import com.fr.third.javax.annotation.Nonnull;
import com.fr.third.org.apache.commons.io.FilenameUtils;
import com.fr.workspace.WorkContext;
import com.fr.workspace.server.lock.TplOperator;
@ -677,32 +678,29 @@ public class MutilTempalteTabPane extends JComponent {
//当前激活的模板
String filename = openedTemplate.get(selectedIndex).getPath();
filename = FilenameUtils.standard(filename);
if (!specifiedTemplate.isALLSaved() && !DesignerMode.isVcsMode()) {
specifiedTemplate.stopEditing();
int returnVal = JOptionPane.showConfirmDialog(DesignerContext.getDesignerFrame(), Toolkit.i18nText("Fine-Design_Basic_Utils_Would_You_Like_To_Save") + " \"" + specifiedTemplate.getEditingFILE() + "\" ?",
ProductConstants.PRODUCT_NAME, JOptionPane.YES_NO_CANCEL_OPTION, JOptionPane.QUESTION_MESSAGE);
if (returnVal == JOptionPane.YES_OPTION) {
specifiedTemplate.saveTemplate();
HistoryTemplateListCache.getInstance().closeSelectedReport(specifiedTemplate);
// release lock
WorkContext.getCurrent().get(TplOperator.class).closeAndFreeFile(specifiedTemplate.getPath());
activeTemplate(filename);
FineLoggerFactory.getLogger().info(Toolkit.i18nText("Fine-Design_Basic_Template_Already_Saved", specifiedTemplate.getEditingFILE().getName()));
closeTpl(specifiedTemplate, filename);
} else if (returnVal == JOptionPane.NO_OPTION) {
closeTpl(specifiedTemplate, filename);
}
} else {
HistoryTemplateListCache.getInstance().closeSelectedReport(specifiedTemplate);
// release lock
WorkContext.getCurrent().get(TplOperator.class).closeAndFreeFile(specifiedTemplate.getPath());
closeTpl(specifiedTemplate, filename);
}
activeTemplate(filename);
FineLoggerFactory.getLogger().info(Toolkit.i18nText("Fine-Design_Basic_Template_Already_Saved", specifiedTemplate.getEditingFILE().getName()));
}
private void closeTpl(@Nonnull JTemplate<?, ?> specifiedTemplate, @Nonnull String fileName) {
HistoryTemplateListCache.getInstance().closeSelectedReport(specifiedTemplate);
// release lock
WorkContext.getCurrent().get(TplOperator.class).closeAndFreeFile(specifiedTemplate.getPath());
activeTemplate(fileName);
}
/**

11
designer-base/src/main/java/com/fr/design/remote/ui/AuthorityListControlPane.java

@ -253,23 +253,16 @@ public class AuthorityListControlPane extends BasicPane {
* @param authorities authority
*/
public void setAuthority(List<DesignAuthority> authorities) {
if (authorities == null || authorities.isEmpty()) {
return;
}
DefaultListModel<DesignAuthority> model = (DefaultListModel<DesignAuthority>) authorityList.getModel();
model.clear();
if (authorities != null && !authorities.isEmpty()) {
for (DesignAuthority authority : authorities) {
model.addElement(authority);
}
int size = model.getSize() - 1;
authorityList.setSelectedIndex(size);
authorityList.ensureIndexIsVisible(size);
}
authorityList.revalidate();
authorityList.repaint();
}

12
designer-base/src/main/java/com/fr/design/remote/ui/UserManagerPane.java

@ -1,5 +1,6 @@
package com.fr.design.remote.ui;
import com.fr.base.BaseUtils;
import com.fr.design.border.UITitledBorder;
import com.fr.design.constants.LayoutConstants;
import com.fr.design.dialog.BasicPane;
@ -240,13 +241,14 @@ public class UserManagerPane extends BasicPane {
);
// 搜索
JPanel searchPanel = new JPanel(new FlowLayout(FlowLayout.LEFT));
searchPanel.setBorder(BorderFactory.createEmptyBorder());
keyField.setPreferredSize(new Dimension(250, 20));
JPanel searchPanel = new JPanel(new FlowLayout(FlowLayout.LEFT, 0, 5));
searchPanel.setBorder(BorderFactory.createEmptyBorder(0, 5, 0, 5));
keyField.setPreferredSize(new Dimension(270, 20));
keyField.requestFocus();
keyField.addKeyListener(keyFieldKeyListener);
keyField.getDocument().addDocumentListener(documentListener);
keyButton.setText(Toolkit.i18nText("Fine-Design_Basic_Remote_Design_Search"));
keyButton.setIcon(BaseUtils.readIcon("com/fr/design/images/buttonicon/user_search_normal.png"));
keyButton.setToolTipText(Toolkit.i18nText("Fine-Design_Basic_Remote_Design_Search"));
keyButton.addActionListener(keyButtonActionListener);
searchPanel.add(keyField);
searchPanel.add(keyButton);
@ -367,9 +369,9 @@ public class UserManagerPane extends BasicPane {
final SwingWorker getMemberWorker = new SwingWorker<List<RemoteDesignMember>, Void>() {
@Override
protected List<RemoteDesignMember> doInBackground() {
addingMembers.clear();
String username = WorkContext.getCurrent().getConnection().getUserName();
synchronized (addingMembers) {
addingMembers.clear();
Collection<RemoteDesignMember> more = WorkContext.getCurrent().get(DecisionOperator.class).getMembers(username, keyword);
pageNum = 1;
if (!more.isEmpty()) {

BIN
designer-base/src/main/resources/com/fr/design/images/buttonicon/user_search_normal.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 444 B

BIN
designer-base/src/main/resources/com/fr/design/images/buttonicon/user_search_normal@2x.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 844 B

2
designer-chart/src/main/java/com/fr/van/chart/designer/component/background/VanChartBackgroundPane.java

@ -114,7 +114,7 @@ public class VanChartBackgroundPane extends BasicPane {
}
private void fireStateChanged() {
protected void fireStateChanged() {
Object[] listeners = listenerList.getListenerList();
ChangeEvent e = null;

2
designer-realize/src/main/java/com/fr/design/webattr/printsettings/NativePrintSettingPane.java

@ -166,7 +166,7 @@ public class NativePrintSettingPane extends JPanel {
printerPane.add(printerComboBox);
// 份数
copySpinner = new UIBasicSpinner(new SpinnerNumberModel(1, 0, Integer.MAX_VALUE, 1));
copySpinner = new UIBasicSpinner(new SpinnerNumberModel(1, 1, Integer.MAX_VALUE, 1));
GUICoreUtils.setColumnForSpinner(copySpinner, 5);
JPanel copyPane = FRGUIPaneFactory.createLeftFlowZeroGapBorderPane();
copyPane.add(copySpinner);

7
designer-realize/src/main/java/com/fr/start/preload/ImagePreLoader.java

@ -19,7 +19,7 @@ public class ImagePreLoader {
int start = 0;
for (int i = 0; i < len; i++) {
if (i != 0 && i % THRESHOLD == 0) {
loadImage(start,i, service);
loadImage(start, i, service);
start = i;
}
if (len - i < THRESHOLD) {
@ -401,6 +401,9 @@ public class ImagePreLoader {
"com/fr/design/images/control/up.png",
"com/fr/design/images/control/down.png",
"com/fr/design/images/condition/bracket.png",
"com/fr/design/images/condition/unBracket.png"
"com/fr/design/images/condition/unBracket.png",
"com/fr/design/images/buttonicon/user_search_normal.png",
"com/fr/design/remote/images/icon_Member_normal@1x.png",
"/com/fr/design/images/buttonicon/add.png"
};
}

Loading…
Cancel
Save