From 97e37a935298bc6ea928acf101c56e1483e5db52 Mon Sep 17 00:00:00 2001 From: Starla Insigna Date: Sun, 8 Feb 2009 17:26:31 -0500 Subject: Fixed Window Selector background alignment In ChoiceWindow, the background picture for the Selector windows wasn't positioned correctly. --- src/com/fourisland/fourpuzzle/window/ChoiceWindow.java | 2 +- src/com/fourisland/fourpuzzle/window/SystemGraphic.java | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) (limited to 'src') diff --git a/src/com/fourisland/fourpuzzle/window/ChoiceWindow.java b/src/com/fourisland/fourpuzzle/window/ChoiceWindow.java index 3b30acc..4754f67 100755 --- a/src/com/fourisland/fourpuzzle/window/ChoiceWindow.java +++ b/src/com/fourisland/fourpuzzle/window/ChoiceWindow.java @@ -79,7 +79,7 @@ public class ChoiceWindow { if (getSelected().equals(choice)) { - g2.drawImage(SystemGraphic.getSelectionBackground(), tx, ty-fh, fw+SPACER-2, fh+SPACER-2, null); + g2.drawImage(SystemGraphic.getSelectionBackground(), tx-1, ty-fh+3, fw+SPACER-2, fh+SPACER-2, null); g2.drawImage(Window.Selector.getImage(fw-Window.Selector.getLeftX(), fh-Window.Selector.getTopY()), tx-SPACER, ty-fh, null); } diff --git a/src/com/fourisland/fourpuzzle/window/SystemGraphic.java b/src/com/fourisland/fourpuzzle/window/SystemGraphic.java index 24e0104..99941d9 100755 --- a/src/com/fourisland/fourpuzzle/window/SystemGraphic.java +++ b/src/com/fourisland/fourpuzzle/window/SystemGraphic.java @@ -6,6 +6,7 @@ package com.fourisland.fourpuzzle.window; import com.fourisland.fourpuzzle.util.ObjectLoader; +import com.fourisland.fourpuzzle.window.Window.SystemArea; import java.awt.Color; import java.awt.Rectangle; import java.awt.image.BufferedImage; @@ -35,7 +36,7 @@ public class SystemGraphic { public static BufferedImage getSelectionBackground() { - return systemGraphic.getSubimage(79, 15, 1, 1); + return systemGraphic.getSubimage(Window.Selector.getX(SystemArea.TOP_LEFT)+15, 15, 1, 1); } public static BufferedImage getChoiceArea(Rectangle sca) -- cgit 1.4.1