Browse Source

Pull request #14429: REPORT-127438 - 设计器样式翻新组件翻新

Merge in DESIGN/design from ~RENEKTON/design:newui to newui

* commit '98624e683964a2d6e8a5eff6b6d5fec629c6aa9c':
  控件管理/报表填报属性/超级链接/服务器参数
  lock图标逻辑修改
  插入单元列排序按钮NPE fix
  控件管理/报表填报属性/超级链接/服务器参数
  控件管理/报表填报属性/超级链接/服务器参数
  控件管理/报表填报属性/超级链接/服务器参数
newui
Renekton-张世豪 4 months ago
parent
commit
7bd6906850
  1. 6
      designer-base/src/main/java/com/fine/theme/light/ui/FineMenuItemUI.java
  2. 6
      designer-base/src/main/java/com/fr/design/gui/imenu/UILockMenuItem.java
  3. 19
      designer-realize/src/main/java/com/fr/design/sort/celldscolumn/CellDSColumnSortGroupPane.java

6
designer-base/src/main/java/com/fine/theme/light/ui/FineMenuItemUI.java

@ -1,8 +1,8 @@
package com.fine.theme.light.ui; package com.fine.theme.light.ui;
import com.fine.theme.icon.LazyIcon;
import com.fine.theme.utils.FineClientProperties; import com.fine.theme.utils.FineClientProperties;
import com.formdev.flatlaf.ui.FlatMenuItemUI; import com.formdev.flatlaf.ui.FlatMenuItemUI;
import com.fr.design.editlock.EditLockUtils;
import javax.swing.JComponent; import javax.swing.JComponent;
import javax.swing.plaf.ComponentUI; import javax.swing.plaf.ComponentUI;
@ -35,7 +35,9 @@ public class FineMenuItemUI extends FlatMenuItemUI {
Object itemType = c.getClientProperty(FineClientProperties.MENU_ITEM_TYPE); Object itemType = c.getClientProperty(FineClientProperties.MENU_ITEM_TYPE);
if (FineClientProperties.MENU_ITEM_TYPE_LOCK.equals(itemType)) { if (FineClientProperties.MENU_ITEM_TYPE_LOCK.equals(itemType)) {
g.drawImage(EditLockUtils.LOCKED_IMAGE, c.getWidth() - rightMargin - iconSize, (c.getHeight() - iconSize) / 2, iconSize, iconSize, null); LazyIcon icon = new LazyIcon("locked");
icon.paintIcon(c, g, c.getWidth() - rightMargin - iconSize, (c.getHeight() - iconSize) / 2);
} }
} }
} }

6
designer-base/src/main/java/com/fr/design/gui/imenu/UILockMenuItem.java

@ -33,7 +33,6 @@ public class UILockMenuItem extends UIMenuItem implements EditLockChangeListener
this.lockedTooltips = lockedTooltips; this.lockedTooltips = lockedTooltips;
this.normalTooltips = normalTooltips; this.normalTooltips = normalTooltips;
this.lockItem = lockItem; this.lockItem = lockItem;
this.putClientProperty(FineClientProperties.MENU_ITEM_TYPE, FineClientProperties.MENU_ITEM_TYPE_LOCK);
} }
public LockItem getLockItem() { public LockItem getLockItem() {
@ -43,6 +42,11 @@ public class UILockMenuItem extends UIMenuItem implements EditLockChangeListener
@Override @Override
public void updateLockedState(EditLockChangeEvent event) { public void updateLockedState(EditLockChangeEvent event) {
this.setToolTipText(event.isLocked() ? lockedTooltips : normalTooltips); this.setToolTipText(event.isLocked() ? lockedTooltips : normalTooltips);
if (event.isLocked()) {
this.putClientProperty(FineClientProperties.MENU_ITEM_TYPE, FineClientProperties.MENU_ITEM_TYPE_LOCK);
} else {
this.putClientProperty(FineClientProperties.MENU_ITEM_TYPE, null);
}
this.repaint(); this.repaint();
} }
} }

19
designer-realize/src/main/java/com/fr/design/sort/celldscolumn/CellDSColumnSortGroupPane.java

@ -27,16 +27,19 @@ public class CellDSColumnSortGroupPane extends AbstractSortGroupPane {
java.util.Map<String, TableDataWrapper> tableDataWrapperMap = java.util.Map<String, TableDataWrapper> tableDataWrapperMap =
DesignTableDataManager.getAllEditingDataSet(HistoryTemplateListCache.getInstance().getCurrentEditingTemplate().getTarget()); DesignTableDataManager.getAllEditingDataSet(HistoryTemplateListCache.getInstance().getCurrentEditingTemplate().getTarget());
Map<String, TableDataWrapper> allDataSetIncludingProcedure = DesignTableDataManager.getAllDataSetIncludingProcedure(tableDataWrapperMap); Map<String, TableDataWrapper> allDataSetIncludingProcedure = DesignTableDataManager.getAllDataSetIncludingProcedure(tableDataWrapperMap);
TableDataWrapper tableDataWrapper = allDataSetIncludingProcedure.get(dsColumn.getDSName()); if (dsColumn != null) {
if (tableDataWrapper != null) { TableDataWrapper tableDataWrapper = allDataSetIncludingProcedure.get(dsColumn.getDSName());
java.util.List<String> columnNameList = tableDataWrapper.calculateColumnNameList(); if (tableDataWrapper != null) {
String[] columnNames = new String[columnNameList.size()]; java.util.List<String> columnNameList = tableDataWrapper.calculateColumnNameList();
columnNameList.toArray(columnNames); String[] columnNames = new String[columnNameList.size()];
cellDSColumnSortItemPane.sortAreaUiComboBox.removeAllItems(); columnNameList.toArray(columnNames);
for (String columnName : columnNames) { cellDSColumnSortItemPane.sortAreaUiComboBox.removeAllItems();
cellDSColumnSortItemPane.sortAreaUiComboBox.addItem(columnName); for (String columnName : columnNames) {
cellDSColumnSortItemPane.sortAreaUiComboBox.addItem(columnName);
}
} }
} }
cellDSColumnSortItemPane.populateBean(sortExpression); cellDSColumnSortItemPane.populateBean(sortExpression);
return cellDSColumnSortItemPane; return cellDSColumnSortItemPane;
} }

Loading…
Cancel
Save