OSDN Git Service

ズームパネルのマウス表示判定のスケール対応
authorseraphy <seraphy@users.osdn.me>
Sun, 13 Jan 2019 04:17:34 +0000 (13:17 +0900)
committerseraphy <seraphy@users.osdn.me>
Sun, 13 Jan 2019 04:17:34 +0000 (13:17 +0900)
src/main/java/charactermanaj/ui/PreviewPanel.java

index 2b0f71b..43cc911 100644 (file)
@@ -394,7 +394,8 @@ public class PreviewPanel extends JPanel {
                        public void mouseMoved(MouseEvent e) {
                                Rectangle rct = previewImgScrollPane.getBounds();
                                int y = e.getY();
-                               if (y > rct.height - appConfig.getZoomPanelActivationArea()) {
+                               UIHelper uiUtl = UIHelper.getInstance();
+                               if (y > rct.height - (int) (appConfig.getZoomPanelActivationArea() * uiUtl.getScaleY())) {
                                        previewControlPanel.setVisible(true);
                                } else {
                                        if ( !previewControlPanel.isPinned()) {