diff --git a/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/windows/WndInfoItem.java b/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/windows/WndInfoItem.java index 45526f713..fd6987eb1 100644 --- a/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/windows/WndInfoItem.java +++ b/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/windows/WndInfoItem.java @@ -66,8 +66,16 @@ public class WndInfoItem extends Window { fillFields( item ); } - - private void fillFields( Heap heap ) { + + @Override + public void hide() { + super.hide(); + if (INSTANCE == this){ + INSTANCE = null; + } + } + + private void fillFields(Heap heap ) { IconTitle titlebar = new IconTitle( heap ); titlebar.color( TITLE_COLOR ); diff --git a/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/windows/WndUseItem.java b/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/windows/WndUseItem.java index 14658f28a..1570f0e1a 100644 --- a/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/windows/WndUseItem.java +++ b/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/windows/WndUseItem.java @@ -164,13 +164,5 @@ public class WndUseItem extends WndInfoItem { return y - 1; } - - @Override - public void hide() { - super.hide(); - if (INSTANCE == this){ - INSTANCE = null; - } - } }