From 3f25c2c3dbd31adfe9a2b1b5dd2a996b05528d19 Mon Sep 17 00:00:00 2001 From: hannibal2 <24389977+hannibal00212@users.noreply.github.com> Date: Sat, 25 Nov 2023 13:46:12 +0100 Subject: Fixed EstimatedItemValue.isCurrentlyShowing logic --- .../at/hannibal2/skyhanni/features/misc/items/EstimatedItemValue.kt | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'src/main/java/at/hannibal2/skyhanni/features/misc') diff --git a/src/main/java/at/hannibal2/skyhanni/features/misc/items/EstimatedItemValue.kt b/src/main/java/at/hannibal2/skyhanni/features/misc/items/EstimatedItemValue.kt index 87394161f..bfdd876c3 100644 --- a/src/main/java/at/hannibal2/skyhanni/features/misc/items/EstimatedItemValue.kt +++ b/src/main/java/at/hannibal2/skyhanni/features/misc/items/EstimatedItemValue.kt @@ -38,7 +38,9 @@ object EstimatedItemValue { private val cache = mutableMapOf>>() private var lastToolTipTime = 0L var gemstoneUnlockCosts = HashMap>>() - var currentlyShowing = false + private var currentlyShowing = false + + fun isCurrentlyShowing() = currentlyShowing && Minecraft.getMinecraft().currentScreen != null @SubscribeEvent fun onRepoReload(event: RepositoryReloadEvent) { -- cgit