summaryrefslogtreecommitdiff
path: root/src/gui/widgets/browserbox.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/gui/widgets/browserbox.cpp')
-rw-r--r--src/gui/widgets/browserbox.cpp4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/gui/widgets/browserbox.cpp b/src/gui/widgets/browserbox.cpp
index 9ffead378..9c5dcc77c 100644
--- a/src/gui/widgets/browserbox.cpp
+++ b/src/gui/widgets/browserbox.cpp
@@ -26,6 +26,8 @@
#include "itemcolormanager.h"
#include "settings.h"
+#include "const/resources/item/cards.h"
+
#include "input/inputmanager.h"
#include "gui/gui.h"
@@ -246,7 +248,7 @@ void BrowserBox::addRow(const std::string &row, const bool atTop)
{
std::vector<int> parts;
splitToIntVector(parts, bLink.link.substr(idx), ',');
- while (parts.size() < 4)
+ while (parts.size() < maxCards)
parts.push_back(0);
const ItemColor itemColor =
ItemColorManager::getColorFromCards(&parts[0]);