From 6b75e5eca3e537384ab482e38f00acab619ae083 Mon Sep 17 00:00:00 2001 From: hzzz Date: Tue, 10 Oct 2017 17:23:31 +0800 Subject: [PATCH 1/4] =?UTF-8?q?tab=E4=B8=8A=E8=BE=B9=E7=9A=84=E7=BA=BF=20?= =?UTF-8?q?=E6=95=B0=E6=8D=AE=E9=9B=86=E5=9B=BE=E6=A0=87=E5=8E=BB=E6=8E=89?= =?UTF-8?q?=20=E6=95=B0=E6=8D=AE=E9=9B=86=E5=92=8C=E6=96=87=E4=BB=B6?= =?UTF-8?q?=E6=A0=91=E7=9A=84=E5=AD=97=E9=A2=9C=E8=89=B2=20=E5=B7=A6?= =?UTF-8?q?=E4=BE=A7=E6=8B=89=E5=8A=A8=E6=9D=A1=E5=9B=BE=E6=A0=87=E5=92=8C?= =?UTF-8?q?=E9=A2=9C=E8=89=B2=20=E8=A1=A8=E6=A0=BC=E9=83=A8=E5=88=86?= =?UTF-8?q?=E6=BB=9A=E5=8A=A8=E6=9D=A1=E4=B8=A4=E4=BE=A7=E7=AE=AD=E5=A4=B4?= =?UTF-8?q?=E5=9B=BE=E6=A0=87=20=E8=A1=A8=E6=A0=BC=E9=83=A8=E5=88=86?= =?UTF-8?q?=E5=B7=A6=E4=B8=8A=E8=A7=92=E5=9B=BE=E6=A0=87?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../design/cell/bar/DynamicScrollButton.java | 41 ++----------- designer/src/com/fr/grid/GridCorner.java | 54 +++++++++--------- .../com/fr/design/constants/UIConstants.java | 7 +++ .../design/data/datapane/TableDataTree.java | 2 +- .../data/datapane/TableDataTreePane.java | 4 +- .../fr/design/file/MutilTempalteTabPane.java | 2 +- .../gui/icontainer/UIResizableContainer.java | 8 +-- .../gui/itree/filetree/EnvFileTree.java | 5 +- .../src/com/fr/design/images/control/dotv.png | Bin 2865 -> 100 bytes 9 files changed, 49 insertions(+), 74 deletions(-) diff --git a/designer/src/com/fr/design/cell/bar/DynamicScrollButton.java b/designer/src/com/fr/design/cell/bar/DynamicScrollButton.java index d4a3db8a73..680244f895 100644 --- a/designer/src/com/fr/design/cell/bar/DynamicScrollButton.java +++ b/designer/src/com/fr/design/cell/bar/DynamicScrollButton.java @@ -1,5 +1,6 @@ package com.fr.design.cell.bar; +import com.fr.design.constants.UIConstants; import com.fr.general.ComparatorUtils; import javax.swing.*; @@ -63,48 +64,16 @@ public class DynamicScrollButton extends BasicArrowButton { private void paintArrow(Graphics g, Dimension size) { switch (direction) { case SwingConstants.NORTH: - g.drawLine(8, 5, 8, 5); - g.drawLine(7, 6, 9, 6); - g.drawLine(6, 7, 10, 7); - g.drawLine(5, 8, 7, 8); - g.drawLine(9, 8, 11, 8); - g.drawLine(4, 9, 6, 9); - g.drawLine(10, 9, 12, 9); - g.drawLine(5, 10, 5, 10); - g.drawLine(11, 10, 11, 10); + g.drawImage(UIConstants.ARROW_NORTH, 0, 0, this); break; case SwingConstants.SOUTH: - g.drawLine(5, 6, 5, 6); - g.drawLine(11, 6, 11, 6); - g.drawLine(4, 7, 6, 7); - g.drawLine(10, 7, 12, 7); - g.drawLine(5, 8, 7, 8); - g.drawLine(9, 8, 11, 8); - g.drawLine(6, 9, 10, 9); - g.drawLine(7, 10, 9, 10); - g.drawLine(8, 11, 8, 11); + g.drawImage(UIConstants.ARROW_SOUTH, 0, 0, this); break; case SwingConstants.EAST: - g.drawLine(6, 5, 6, 5); - g.drawLine(6, 11, 6, 11); - g.drawLine(7, 4, 7, 6); - g.drawLine(7, 10, 7, 12); - g.drawLine(8, 5, 8, 7); - g.drawLine(8, 9, 8, 11); - g.drawLine(9, 6, 9, 10); - g.drawLine(10, 7, 10, 9); - g.drawLine(11, 8, 11, 8); + g.drawImage(UIConstants.ARROW_EAST, 0, 0, this); break; case SwingConstants.WEST: - g.drawLine(4, 8, 4, 8); - g.drawLine(5, 7, 5, 9); - g.drawLine(6, 6, 6, 10); - g.drawLine(7, 5, 7, 7); - g.drawLine(7, 9, 7, 11); - g.drawLine(8, 4, 8, 6); - g.drawLine(8, 10, 8, 12); - g.drawLine(9, 5, 9, 5); - g.drawLine(9, 11, 9, 11); + g.drawImage(UIConstants.ARROW_WEST, 0, 0, this); break; } } diff --git a/designer/src/com/fr/grid/GridCorner.java b/designer/src/com/fr/grid/GridCorner.java index 91891fd44d..8cb236d2d9 100644 --- a/designer/src/com/fr/grid/GridCorner.java +++ b/designer/src/com/fr/grid/GridCorner.java @@ -3,18 +3,15 @@ */ package com.fr.grid; -import java.awt.Color; -import java.awt.Dimension; -import java.awt.Graphics; -import java.awt.Graphics2D; -import java.awt.geom.Rectangle2D; - -import javax.swing.event.MouseInputListener; - import com.fr.base.GraphHelper; import com.fr.base.ScreenResolution; +import com.fr.design.constants.UIConstants; import com.fr.design.mainframe.ElementCasePane; +import javax.swing.event.MouseInputListener; +import java.awt.*; +import java.awt.geom.Rectangle2D; + /** * GridCorner used to paint and edit grid cornor. */ @@ -29,16 +26,16 @@ public class GridCorner extends BaseGridComponent { this.addMouseListener(l); this.addMouseMotionListener(l); } - + /** * Paints component */ @Override - public void paintComponent(Graphics g) { + public void paintComponent(Graphics g) { Graphics2D g2d = (Graphics2D) g; ElementCasePane reportPane = this.getElementCasePane(); - float time = (float)reportPane.getResolution()/ ScreenResolution.getScreenResolution(); + float time = (float) reportPane.getResolution() / ScreenResolution.getScreenResolution(); //size Dimension size = this.getSize(); Rectangle2D rect2D = new Rectangle2D.Double(0, 0, size.getWidth(), size.getHeight()); @@ -50,9 +47,9 @@ public class GridCorner extends BaseGridComponent { g2d.setPaint(reportPane.getBackground()); GraphHelper.fill(g2d, rect2D); } - + paintArc(g2d, size, time); - + //画左边的边框线. g2d.setColor(reportPane.getGridColumn().getSeparatorLineColor()); GraphHelper.drawLine(g2d, 0, 0, 0, size.getHeight()); @@ -66,7 +63,7 @@ public class GridCorner extends BaseGridComponent { * Gets the preferred size. */ @Override - public Dimension getPreferredSize() { + public Dimension getPreferredSize() { ElementCasePane reportPane = this.getElementCasePane(); if (!reportPane.isColumnHeaderVisible() || !reportPane.isRowHeaderVisible()) { @@ -74,28 +71,31 @@ public class GridCorner extends BaseGridComponent { } return new Dimension(reportPane.getGridRow().getPreferredSize().width, - reportPane.getGridColumn().getPreferredSize().height); + reportPane.getGridColumn().getPreferredSize().height); } /** * Gets corner background. */ @Override - public Color getBackground() { + public Color getBackground() { return super.getBackground(); } - + private void paintArc(Graphics2D g2d, Dimension size, float time) { - g2d.setColor(Color.gray); - int width = (int) (size.width - (16 * time)); - int avgWidth = width / 3; - int height = (int) (size.height - (8 * time)); - int avgHeight = height / 3; - for (int i = 0; i < 3; i ++) { - for (int j = 0; j < 3; j ++) { - GraphHelper.fillArc(g2d, (8 * time) + (i * avgWidth), (4 * time) + (j * avgHeight), 3, 3, 0, 360); - } - } + g2d.setColor(UIConstants.LINE_COLOR); + float height = 2 * time; + float width = 2 * time; + float hgap = 4 * time; + float vgap = 3 * time; + + int x = (int) ((size.width - (hgap * 2 + width * 3)) / 2); + int y = (int) (size.height - (vgap * 2 + height * 3)); + for (int i = 0; i < 3; i++) { + for (int j = 0; j < 3; j++) { + GraphHelper.fillRect(g2d, x + (i * hgap), y + (j * vgap), width, height); + } + } } } \ No newline at end of file diff --git a/designer_base/src/com/fr/design/constants/UIConstants.java b/designer_base/src/com/fr/design/constants/UIConstants.java index 5552b09bc7..fde81e8859 100644 --- a/designer_base/src/com/fr/design/constants/UIConstants.java +++ b/designer_base/src/com/fr/design/constants/UIConstants.java @@ -120,6 +120,12 @@ public interface UIConstants { public static final BufferedImage DRAG_BAR = BaseUtils.readImage("com/fr/design/images/control/bar.png"); + public static final BufferedImage DRAG_BAR_LIGHT = BaseUtils.readImage("com/fr/design/images/control/bar-light.png"); + public static final BufferedImage ARROW_NORTH = BaseUtils.readImage("com/fr/design/images/control/up_arrow.png"); + public static final BufferedImage ARROW_SOUTH = BaseUtils.readImage("com/fr/design/images/control/down_arrow.png"); + public static final BufferedImage ARROW_EAST = BaseUtils.readImage("com/fr/design/images/control/east_arrow.png"); + public static final BufferedImage ARROW_WEST = BaseUtils.readImage("com/fr/design/images/control/west_arrow.png"); + public static final BufferedImage DRAG_BAR_RIGHT = BaseUtils.readImage("com/fr/design/images/control/barm.png"); public static final BufferedImage DRAG_BAR_LEFT = BaseUtils.readImage("com/fr/design/images/control/barl.png"); public static final BufferedImage DRAG_UP_NORMAL = BaseUtils.readImage("com/fr/design/images/control/upnor.png"); @@ -131,6 +137,7 @@ public interface UIConstants { public static final BufferedImage DRAG_LEFT_NORMAL = BaseUtils.readImage("com/fr/design/images/control/leftnor.png"); public static final BufferedImage DRAG_LEFT_PRESS = BaseUtils.readImage("com/fr/design/images/control/leftpre.png"); public static final BufferedImage DRAG_DOT = BaseUtils.readImage("com/fr/design/images/control/dot.png"); + public static final BufferedImage DRAG_LINE = BaseUtils.readImage("com/fr/design/images/control/dot-line.png"); public static final BufferedImage ACCESSIBLE_EDITOR_DOT = BaseUtils.readImage("com/fr/design/images/control/dot.png"); public static final BufferedImage DRAG_DOT_VERTICAL = BaseUtils.readImage("com/fr/design/images/control/dotv.png"); public static final BufferedImage POP_BUTTON_DOWN = BaseUtils.readImage("com/fr/design/images/buttonicon/popdownarrow.png"); diff --git a/designer_base/src/com/fr/design/data/datapane/TableDataTree.java b/designer_base/src/com/fr/design/data/datapane/TableDataTree.java index 8082d8c1ea..2d3b5e4bec 100644 --- a/designer_base/src/com/fr/design/data/datapane/TableDataTree.java +++ b/designer_base/src/com/fr/design/data/datapane/TableDataTree.java @@ -75,7 +75,7 @@ public class TableDataTree extends UserObjectRefreshJTree { this.setSize(dim); this.setPreferredSize(dim); this.setBackgroundNonSelectionColor(UIConstants.TREE_BACKGROUND); - this.setForeground(UIConstants.FONT_COLOR); + this.setTextSelectionColor(Color.WHITE); this.setBackgroundSelectionColor(UIConstants.FLESH_BLUE); return this; } diff --git a/designer_base/src/com/fr/design/data/datapane/TableDataTreePane.java b/designer_base/src/com/fr/design/data/datapane/TableDataTreePane.java index 7a4cf52042..3a3e877eb6 100644 --- a/designer_base/src/com/fr/design/data/datapane/TableDataTreePane.java +++ b/designer_base/src/com/fr/design/data/datapane/TableDataTreePane.java @@ -159,10 +159,10 @@ public class TableDataTreePane extends BasicTableDataTreePane { } protected void initbuttonGroup() { - Icon[] iconArray = {BaseUtils.readIcon("/com/fr/design/images/data/datasource.png"), BaseUtils.readIcon("/com/fr/design/images/data/dock/serverdatabase.png")}; +// Icon[] iconArray = {BaseUtils.readIcon("/com/fr/design/images/data/datasource.png"), BaseUtils.readIcon("/com/fr/design/images/data/dock/serverdatabase.png")}; final Integer[] modeArray = {TEMPLATE_TABLE_DATA, SERVER_TABLE_DATA}; String[] textArray = {Inter.getLocText(new String[]{"Template", "DS-TableData"}), Inter.getLocText("DS-Server_TableData")}; - buttonGroup = new UIHeadGroup(iconArray, textArray) { + buttonGroup = new UIHeadGroup(textArray) { public void tabChanged(int index) { if (op != null) { op.setDataMode(modeArray[buttonGroup.getSelectedIndex()]); diff --git a/designer_base/src/com/fr/design/file/MutilTempalteTabPane.java b/designer_base/src/com/fr/design/file/MutilTempalteTabPane.java index 44307b018e..4c4dc8236d 100644 --- a/designer_base/src/com/fr/design/file/MutilTempalteTabPane.java +++ b/designer_base/src/com/fr/design/file/MutilTempalteTabPane.java @@ -496,7 +496,7 @@ public class MutilTempalteTabPane extends JComponent implements MouseListener, M */ private int paintSelectedTab(Graphics2D g2d, Icon sheeticon, double templateStartX, String sheetName, Icon closeIcon) { double[] x = {templateStartX, templateStartX, templateStartX + realWidth, templateStartX + realWidth, templateStartX}; - double[] y = {-1, getHeight(), getHeight(), -1, -1}; + double[] y = {1, getHeight() + 1, getHeight() + 1, 1, 1}; RoundRectangle2D.Double rect1 = new RoundRectangle2D.Double(templateStartX, 1, this.getWidth(), this.getHeight(), 7, 7); g2d.setPaint(new GradientPaint(1, 1, UIConstants.SELECT_TAB, 1, getHeight() - 1, UIConstants.SELECT_TAB)); //选了30度和60度的特殊角度的x,y作为经过的两个点的坐标 diff --git a/designer_base/src/com/fr/design/gui/icontainer/UIResizableContainer.java b/designer_base/src/com/fr/design/gui/icontainer/UIResizableContainer.java index 5d35bf02e0..5f28fadde0 100644 --- a/designer_base/src/com/fr/design/gui/icontainer/UIResizableContainer.java +++ b/designer_base/src/com/fr/design/gui/icontainer/UIResizableContainer.java @@ -397,8 +397,8 @@ public class UIResizableContainer extends JPanel { Image upButton = (upModel == UIConstants.MODEL_NORMAL ? UIConstants.DRAG_UP_NORMAL : UIConstants.DRAG_UP_PRESS); Image downButton = (downModel == UIConstants.MODEL_NORMAL ? UIConstants.DRAG_DOWN_NORMAL : UIConstants.DRAG_DOWN_PRESS); - g.drawImage(UIConstants.DRAG_BAR, 0, 0, getWidth(), getHeight(), null); - g.drawImage(UIConstants.DRAG_DOT, (getWidth() - toolPaneHeight) / 2, 3, toolPaneHeight, 5, null); + g.drawImage(UIConstants.DRAG_BAR_LIGHT, 0, 0, getWidth(), getHeight(), null); + g.drawImage(UIConstants.DRAG_LINE, (getWidth() - toolPaneHeight) / 2, 3, toolPaneHeight, 5, null); g.drawImage(upButton, ARROW_MARGIN, 3, toolPaneHeight, 5, null); g.drawImage(downButton, getWidth() - toolPaneHeight - ARROW_MARGIN, 3, toolPaneHeight, 5, null); } @@ -488,7 +488,7 @@ public class UIResizableContainer extends JPanel { public void paint(Graphics g) { Image button; if (direction == Constants.RIGHT) { - g.drawImage(UIConstants.DRAG_BAR, 0, 0, toolPaneHeight, getHeight(), null); + g.drawImage(UIConstants.DRAG_BAR_LIGHT, 0, 0, toolPaneHeight, getHeight(), null); if (containerWidth == toolPaneHeight) { if (model == UIConstants.MODEL_NORMAL) { button = UIConstants.DRAG_RIGHT_NORMAL; @@ -504,7 +504,7 @@ public class UIResizableContainer extends JPanel { } g.drawImage(button, 3, ARROW_MARGIN_VERTICAL, 5, toolPaneHeight, null); } else { - g.drawImage(UIConstants.DRAG_BAR, 0, 0, toolPaneHeight, getHeight(), null); + g.drawImage(UIConstants.DRAG_BAR_LIGHT, 0, 0, toolPaneHeight, getHeight(), null); if (containerWidth == toolPaneHeight) { if (model == UIConstants.MODEL_NORMAL) { button = UIConstants.DRAG_LEFT_NORMAL; diff --git a/designer_base/src/com/fr/design/gui/itree/filetree/EnvFileTree.java b/designer_base/src/com/fr/design/gui/itree/filetree/EnvFileTree.java index 8cfde735db..7aa9dd2c48 100644 --- a/designer_base/src/com/fr/design/gui/itree/filetree/EnvFileTree.java +++ b/designer_base/src/com/fr/design/gui/itree/filetree/EnvFileTree.java @@ -1,7 +1,6 @@ package com.fr.design.gui.itree.filetree; -import java.awt.Component; -import java.awt.Dimension; +import java.awt.*; import java.io.File; import java.util.ArrayList; import java.util.Arrays; @@ -107,7 +106,7 @@ public class EnvFileTree extends RefreshableJTree { dim.height += 2; this.setPreferredSize(dim); this.setBackgroundNonSelectionColor(UIConstants.TREE_BACKGROUND); - this.setForeground(UIConstants.FONT_COLOR); + this.setTextSelectionColor(Color.WHITE); this.setBackgroundSelectionColor(UIConstants.FLESH_BLUE); return this; } diff --git a/designer_base/src/com/fr/design/images/control/dotv.png b/designer_base/src/com/fr/design/images/control/dotv.png index a9a1b9048cc21c664b1769772de7cced66e188d4..a806ba2eaacf741188e334326949e8058c42b9a7 100644 GIT binary patch delta 70 zcmdlemNG%bfw4Hq-HBn{IhmIX3=DFfE{-7_vdIYwoI26l-q?FE_oN+KHe0Oe#+!qB aYz&KLvc669OKJqFWbkzLb6Mw<&;$TD;uq@x delta 2857 zcmV+^3)b{xu@;ade+h6%S#tmY3ljhU3ljkVnw%H_018cMLqkwdXm50Hb7*gHAW1_* zAaHVTW@&6?004N}ol|#MllK-r-}hw?RzleDv6pOt03su-2*?mwq7ae*VT2G8K*fcK z3RV;q5u8X>#DdidNS%n{peVR!L5hf4i&b1W?jPKzwS9W;f9>u2*ZaKZoag+`dCw1k z5fUbm=AvoAR{$W90N^4L=L-RlQUJ&HumpsYY5E(E}?0f1Sy zGDiY{y#)Yvj#!WnKwtoXnL;eg03b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o{xK_e|rb^MeplsbZ>0jufM;t32jm~jUGrk zaOInTZ`zyfns>EuS}G30LFK_G-==(f<51|K&cocp&EJ`SxAh3?NO>#LI=^+SEu(Fq zJ)ynt=!~PC9bO$rzPJB=?=jR&z?UQbnZ;IU-!xL-sg{9@Vs#JBKKn3CAUkhJ+3`ResKNaNUvLO>t*-L z?N>ambo5Q@JJIjcfBI^`)pOVQ*DhV3dA;w(>>IakCfyvkCA#(acJ}QTcM9%I++BK) zc(44v+WqPW`VZ=VwEnSWz-{38V8CF{f5TZ1?+yuvp8k~o(}&^GN6bgnBSs^QkDVVM z8x0!0@?_4F;is~v6VJ+iR{weHbF1gy{o?ye&shA}@C*5i&%dsDsq=F0tEsO#$0Nrd zyv}(&@uvK(&f9(OxbM2($Gsn!DEvVFQ1j9HW5=h^Pxn6OeE$3|_k{ENCDNZWe*gdg zAY({UO#lFTB>(_`g8%^e{{R4h=>PzAFaQARU;qF*m;eA5Z<1fdMgRZ+UP(kjRCwB~ zj4=&>Fcbw3aDsuRshRumE(Dc++2EX5%B~oD<-sBb4cmKRhM5nSGy<7JzdALBuWL1gI8C00000NkvXX Hu0mjf*vEI> From 8602863faf0caa6d0c3f1e35a1e3acdcb444f067 Mon Sep 17 00:00:00 2001 From: hzzz Date: Tue, 10 Oct 2017 17:23:42 +0800 Subject: [PATCH 2/4] =?UTF-8?q?=E5=9B=BE=E6=A0=87=E6=9B=BF=E6=8D=A2?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- designer_base/src/com/fr/design/.DS_Store | Bin 0 -> 6148 bytes .../src/com/fr/design/images/.DS_Store | Bin 0 -> 8196 bytes .../src/com/fr/design/images/control/.DS_Store | Bin 0 -> 10244 bytes .../com/fr/design/images/control/bar-light.png | Bin 0 -> 106 bytes .../com/fr/design/images/control/dot-line.png | Bin 0 -> 106 bytes .../com/fr/design/images/control/down_arrow.png | Bin 0 -> 218 bytes .../com/fr/design/images/control/east_arrow.png | Bin 0 -> 241 bytes .../com/fr/design/images/control/up_arrow.png | Bin 0 -> 190 bytes .../com/fr/design/images/control/west_arrow.png | Bin 0 -> 242 bytes 9 files changed, 0 insertions(+), 0 deletions(-) create mode 100644 designer_base/src/com/fr/design/.DS_Store create mode 100644 designer_base/src/com/fr/design/images/.DS_Store create mode 100644 designer_base/src/com/fr/design/images/control/.DS_Store create mode 100644 designer_base/src/com/fr/design/images/control/bar-light.png create mode 100644 designer_base/src/com/fr/design/images/control/dot-line.png create mode 100644 designer_base/src/com/fr/design/images/control/down_arrow.png create mode 100644 designer_base/src/com/fr/design/images/control/east_arrow.png create mode 100644 designer_base/src/com/fr/design/images/control/up_arrow.png create mode 100644 designer_base/src/com/fr/design/images/control/west_arrow.png diff --git a/designer_base/src/com/fr/design/.DS_Store b/designer_base/src/com/fr/design/.DS_Store new file mode 100644 index 0000000000000000000000000000000000000000..3838ca5a172699ad8de11d98cef8ea09ecffeb9a GIT binary patch literal 6148 zcmeHKJC4FY47FJb5Dn#)bA`RZ2*C-s04tETK|$hIr{Y{3jpvULQL@cSG^=OHels4w ziSmj#77<-sc3&cM5t+aZ3UH7Vo6ULp&Ru15uUirsn ze`tQ<=3y$cRDcRl0V+TRsK6f-u-*%s%mNvy02QDDPX+AzP~e6&u?_T32ZE0Pz%kNp zSods4KR{c};8sosPWIf&3XTU1(I`-3mMaRreLa literal 0 HcmV?d00001 diff --git a/designer_base/src/com/fr/design/images/.DS_Store b/designer_base/src/com/fr/design/images/.DS_Store new file mode 100644 index 0000000000000000000000000000000000000000..44e20257a909636796ce6fe737b51f9c8e2e94fd GIT binary patch literal 8196 zcmeHM%Wl&^6unalbqEiqG>{4w7FmEqkx~Q_ED#}-M**p!t{_z@shvy{3o{ehlLn|N zMSK7s09zg(z=k!Ce?V;b0Tygv&7B#il%!o2keG?)o|~Ebu+KQQ?*srysa>B0$N_+b zU80>vu}PEjvJbSOWMl-9pg#Zy1_9I*4w#z(!+>GHFkl!k3>XIf0S54yEt|E)b6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xg$1fJwc#lyE?zi~_cC0PVQ2zSI0Pk*HSpS~GheLzUx-bMQa4;uZiyHyeGkCiCxvX2~M*@JHhTV$W) z%;E|G%P#T*`y{`|HCuZ`jas?fP|j=WB;M&NOaxlyYcm zFljiF@MhPpUCjoj22!gT6+Bl=4sX1n(7Yj&?c_sN2j?>m66+TQdY*D-U?}x+agbD+ RQU`P&gQu&X%Q~loCIE&}SR?=d literal 0 HcmV?d00001 diff --git a/designer_base/src/com/fr/design/images/control/east_arrow.png b/designer_base/src/com/fr/design/images/control/east_arrow.png new file mode 100644 index 0000000000000000000000000000000000000000..918d75a9f910fdabb1e3f79faac235803684e51a GIT binary patch literal 241 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!61|;P_|4#%`jKx9jP7LeL$-D$|R(rZQhFAzD zCrHd&uyUp6_Js=%_DI|}Obq_={=U7R!aXLF6LPa{Hc1#8u^+Q5cyJ&%J^gub{l7nv zyoTd0x1ULBNs1z{BnPPeK_;WW`*escQa&5EYLo5{CGBl zhCpNE&aT#0RS^m8qa90 literal 0 HcmV?d00001 diff --git a/designer_base/src/com/fr/design/images/control/west_arrow.png b/designer_base/src/com/fr/design/images/control/west_arrow.png new file mode 100644 index 0000000000000000000000000000000000000000..5693190f9646d3cf5fca20ff24bf9d114e07c833 GIT binary patch literal 242 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!61|;P_|4#%`jKx9jP7LeL$-D$|)_A%&hFAzD zCrC&xSh(=unw2X(#b@Ww+`y^S&1h=<=lAz~Zh>N@?!z}Kco}YG@n6}|)!M2ml5s(E zhFZ!j!I{lx*fRfpette{!n0kwb~T?UI+3%6t>F((k(uIIh2{@cj5pO{a?)~y*!g5C zUcGr!!}Ww!U~m2Zf9*G}G#=R?#W0B>Q|Xw%9JT{Ig(W36f4{%Kf7Ria!iiLc!W0Js po(9IMhR)8D>>c}+vt`_J820A+P5iQ={VdSk44$rjF6*2UngD4wV8H+Y literal 0 HcmV?d00001 From a6aaeeebb7187791c0c5005fefaeea11484169cc Mon Sep 17 00:00:00 2001 From: hzzz Date: Tue, 10 Oct 2017 17:23:59 +0800 Subject: [PATCH 3/4] tmp --- designer_base/src/com/fr/design/.DS_Store | Bin 6148 -> 0 bytes .../src/com/fr/design/images/.DS_Store | Bin 8196 -> 0 bytes .../src/com/fr/design/images/control/.DS_Store | Bin 10244 -> 0 bytes 3 files changed, 0 insertions(+), 0 deletions(-) delete mode 100644 designer_base/src/com/fr/design/.DS_Store delete mode 100644 designer_base/src/com/fr/design/images/.DS_Store delete mode 100644 designer_base/src/com/fr/design/images/control/.DS_Store diff --git a/designer_base/src/com/fr/design/.DS_Store b/designer_base/src/com/fr/design/.DS_Store deleted file mode 100644 index 3838ca5a172699ad8de11d98cef8ea09ecffeb9a..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 6148 zcmeHKJC4FY47FJb5Dn#)bA`RZ2*C-s04tETK|$hIr{Y{3jpvULQL@cSG^=OHels4w ziSmj#77<-sc3&cM5t+aZ3UH7Vo6ULp&Ru15uUirsn ze`tQ<=3y$cRDcRl0V+TRsK6f-u-*%s%mNvy02QDDPX+AzP~e6&u?_T32ZE0Pz%kNp zSods4KR{c};8sosPWIf&3XTU1(I`-3mMaRreLa diff --git a/designer_base/src/com/fr/design/images/.DS_Store b/designer_base/src/com/fr/design/images/.DS_Store deleted file mode 100644 index 44e20257a909636796ce6fe737b51f9c8e2e94fd..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 8196 zcmeHM%Wl&^6unalbqEiqG>{4w7FmEqkx~Q_ED#}-M**p!t{_z@shvy{3o{ehlLn|N zMSK7s09zg(z=k!Ce?V;b0Tygv&7B#il%!o2keG?)o|~Ebu+KQQ?*srysa>B0$N_+b zU80>vu}PEjvJbSOWMl-9pg#Zy1_9I*4w#z(!+>GHFkl!k3>XIf0S54yEt|E)b6?LI zX&5jJ{Fe;K`-6jBVllz4Ms@2zp-KS6VH{Qsb*uxFkCR|A!LCN-iZON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+0800 Subject: [PATCH 4/4] =?UTF-8?q?=E5=B1=9E=E6=80=A7=E6=A0=87=E9=A2=98?= =?UTF-8?q?=E6=A0=8F=E7=82=B9=E5=87=BB=E5=8F=98=E8=89=B2=E6=95=88=E6=9E=9C?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../com/fr/design/foldablepane/HeaderPane.java | 8 +++++++- .../design/foldablepane/UIExpandablePane.java | 17 ++++++++++++++++- 2 files changed, 23 insertions(+), 2 deletions(-) diff --git a/designer_base/src/com/fr/design/foldablepane/HeaderPane.java b/designer_base/src/com/fr/design/foldablepane/HeaderPane.java index 8e99896bc1..31cc290324 100644 --- a/designer_base/src/com/fr/design/foldablepane/HeaderPane.java +++ b/designer_base/src/com/fr/design/foldablepane/HeaderPane.java @@ -22,10 +22,15 @@ public class HeaderPane extends JPanel { private int headHeight; private Color bgColor; private boolean isShow; + private boolean isPressed = false; private String title; private Image image; private int fontSize; + public void setPressed(boolean pressed) { + this.isPressed = pressed; + } + public void setShow(boolean isShow) { this.isShow = isShow; } @@ -60,7 +65,8 @@ public class HeaderPane extends JPanel { private BufferedImage createPanelImage() { BufferedImage panelImage = new BufferedImage(getWidth(), headHeight, BufferedImage.TYPE_INT_ARGB); Graphics2D g2d = panelImage.createGraphics(); - g2d.setColor(UIConstants.COMPONENT_BACKGROUND_COLOR); + + g2d.setColor(isPressed ? UIConstants.POPUP_TITLE_BACKGROUND : UIConstants.COMPONENT_BACKGROUND_COLOR); headWidth = this.getWidth(); g2d.fillRect(0, 0, headWidth, headHeight); g2d.setFont(new Font("SimSun", 0, fontSize)); diff --git a/designer_base/src/com/fr/design/foldablepane/UIExpandablePane.java b/designer_base/src/com/fr/design/foldablepane/UIExpandablePane.java index 924415aea3..9ed2d9757b 100644 --- a/designer_base/src/com/fr/design/foldablepane/UIExpandablePane.java +++ b/designer_base/src/com/fr/design/foldablepane/UIExpandablePane.java @@ -58,7 +58,8 @@ public class UIExpandablePane extends JPanel { } class PanelAction extends MouseAdapter { - public void mousePressed(MouseEvent e) { + @Override + public void mouseClicked(MouseEvent e) { HeaderPane hp = (HeaderPane) e.getSource(); if (contentPanel.isShowing()) { contentPanel.setVisible(false); @@ -67,9 +68,23 @@ public class UIExpandablePane extends JPanel { contentPanel.setVisible(true); hp.setShow(true); } + hp.setPressed(false); hp.getParent().validate(); hp.getParent().repaint(); } + + public void mousePressed(MouseEvent e) { + HeaderPane hp = (HeaderPane) e.getSource(); + hp.setPressed(true); + hp.getParent().repaint(); + } + + @Override + public void mouseExited(MouseEvent e) { + HeaderPane hp = (HeaderPane) e.getSource(); + hp.setPressed(false); + hp.getParent().repaint(); + } }