prevent bazaar current shop button from becoming unselected

This commit is contained in:
myk
2013-02-01 17:18:30 +00:00
parent 96b569cc24
commit 152e8fa9fc
3 changed files with 3 additions and 4 deletions

View File

@@ -186,7 +186,7 @@ public class SSubmenuQuestUtil {
view0.getLblWinStreak().setText(
"<html>Win streak: " + qA.getWinStreakCurrent()
+ "<br>&nbsp; (Best:" + qA.getWinStreakBest() + ")</html>");
+ "<br>&nbsp; (Best: " + qA.getWinStreakBest() + ")</html>");
// Current deck message
final JLabel lblCurrentDeck = view0.getLblCurrentDeck();

View File

@@ -219,11 +219,9 @@ public class FLabel extends JLabel implements ILocalRepaint {
private final Color d50 = FSkin.stepColor(clrMain, -50);
private final Color d30 = FSkin.stepColor(clrMain, -30);
private final Color d10 = FSkin.stepColor(clrMain, -10);
private final Color l00 = FSkin.stepColor(clrMain, 0);
private final Color l10 = FSkin.stepColor(clrMain, 10);
private final Color l20 = FSkin.stepColor(clrMain, 20);
private final Color l30 = FSkin.stepColor(clrMain, 30);
private final Color l40 = FSkin.stepColor(clrMain, 40);
// Custom properties, assigned either at realization (using builder)
// or dynamically (using methods below).

View File

@@ -59,7 +59,7 @@ public class ViewBazaarUI extends FPanel {
final FLabel lbl = new FLabel.ButtonBuilder().text(s + " ")
.fontAlign(SwingConstants.RIGHT).iconInBackground(true)
.fontSize(16).icon(FSkin.getIcon(bazaar.getStall(s).getIcon())).selectable().build();
.fontSize(16).icon(FSkin.getIcon(bazaar.getStall(s).getIcon())).build();
pnlAllStalls.add(lbl, "h 80px!, w 90%!, gap 0 0 10px 10px");
@@ -67,6 +67,7 @@ public class ViewBazaarUI extends FPanel {
@Override
public void execute() {
if (previousSelected != null) { previousSelected.setSelected(false); }
lbl.setSelected(true);
previousSelected = lbl;
control.showStall(s);
}