From 81c9ef947ff8c5309d3b4366f6a4beaac34eb81d Mon Sep 17 00:00:00 2001
From: psi29a <psi29a@gmail.com>
Date: Sun, 26 Dec 2021 19:50:19 +0000
Subject: [PATCH] Resovles #6519 Do not display effects duration for ingredient

---
 CHANGELOG.md                   | 1 +
 apps/openmw/mwgui/tooltips.cpp | 1 +
 2 files changed, 2 insertions(+)

diff --git a/CHANGELOG.md b/CHANGELOG.md
index e4094f0ec2..601bbeaeba 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -92,6 +92,7 @@
     Bug #6473: Strings from NIF should be parsed only to first null terminator
     Bug #6493: Unlocking owned but not locked or unlocked containers is considered a crime
     Bug #6517: Rotations for KeyframeData in NIFs should be optional
+    Bug #6519: Effects tooltips for ingredients work incorrectly
     Feature #890: OpenMW-CS: Column filtering
     Feature #1465: "Reset" argument for AI functions
     Feature #2554: Modifying an object triggers the instances table to scroll to the corresponding record
diff --git a/apps/openmw/mwgui/tooltips.cpp b/apps/openmw/mwgui/tooltips.cpp
index 84d8b65592..0a2fd4c448 100644
--- a/apps/openmw/mwgui/tooltips.cpp
+++ b/apps/openmw/mwgui/tooltips.cpp
@@ -493,6 +493,7 @@ namespace MWGui
             std::vector<MyGUI::Widget*> effectItems;
             int flag = info.isPotion ? Widgets::MWEffectList::EF_NoTarget : 0;
             flag |= info.isIngredient ? Widgets::MWEffectList::EF_NoMagnitude : 0;
+            flag |= info.isIngredient ? Widgets::MWEffectList::EF_Constant : 0;
             effectsWidget->createEffectWidgets(effectItems, effectArea, coord, true, flag);
             totalSize.height += coord.top-6;
             totalSize.width = std::max(totalSize.width, coord.width);