diff --git a/src/com/shatteredpixel/shatteredpixeldungeon/ui/RedButton.java b/src/com/shatteredpixel/shatteredpixeldungeon/ui/RedButton.java index 84dbe3bfb..b79480c5d 100644 --- a/src/com/shatteredpixel/shatteredpixeldungeon/ui/RedButton.java +++ b/src/com/shatteredpixel/shatteredpixeldungeon/ui/RedButton.java @@ -36,9 +36,15 @@ public class RedButton extends Button { protected Image icon; public RedButton( String label ) { + this(label, 9); + } + + public RedButton( String label, int size ){ super(); - + + text = PixelScene.renderText( size ); text.text( label ); + add( text ); } @Override @@ -47,9 +53,6 @@ public class RedButton extends Button { bg = Chrome.get( Chrome.Type.BUTTON ); add( bg ); - - text = PixelScene.renderText( 9 ); - add( text ); } @Override diff --git a/src/com/shatteredpixel/shatteredpixeldungeon/windows/WndItem.java b/src/com/shatteredpixel/shatteredpixeldungeon/windows/WndItem.java index c9166e8ed..1ee517059 100644 --- a/src/com/shatteredpixel/shatteredpixeldungeon/windows/WndItem.java +++ b/src/com/shatteredpixel/shatteredpixeldungeon/windows/WndItem.java @@ -67,7 +67,7 @@ public class WndItem extends Window { if (Dungeon.hero.isAlive() && owner != null) { for (final String action:item.actions( Dungeon.hero )) { - RedButton btn = new RedButton( Messages.get(item, "ac_" + action) ) { + RedButton btn = new RedButton( Messages.get(item, "ac_" + action), 8 ) { @Override protected void onClick() { item.execute( Dungeon.hero, action );