Browse Source

REPORT-55757 【组件背景分离】组件复用-标题图案预览图,悬浮时出现的遮罩和删除图标,鼠标如果从左边/上边滑出,则删除图标消失;但从右边/下边滑出,删除图标还在

【问题原因】
不需要在mouseExited里加多余的判断
【改动思路】
同上
final/10.0
Starryi 3 years ago
parent
commit
76f76a8915
  1. 4
      designer-form/src/main/java/com/fr/design/gui/xpane/TitleInsetImagePane.java

4
designer-form/src/main/java/com/fr/design/gui/xpane/TitleInsetImagePane.java

@ -115,14 +115,10 @@ public class TitleInsetImagePane extends JPanel implements UIObserver {
@Override @Override
public void mouseExited(MouseEvent e) { public void mouseExited(MouseEvent e) {
super.mouseExited(e); super.mouseExited(e);
int x = e.getX();
int y = e.getY();
if (x <= 0 || getWidth() <= x || y <= 0 || y >= getHeight()) {
imagePreviewOverlayPane.setVisible(false); imagePreviewOverlayPane.setVisible(false);
imageDeleteButton.setVisible(false); imageDeleteButton.setVisible(false);
imageDeleteButton.setEnabled(false); imageDeleteButton.setEnabled(false);
} }
}
}); });
return TableLayoutHelper.createCommonTableLayoutPane( return TableLayoutHelper.createCommonTableLayoutPane(

Loading…
Cancel
Save