Skip to content

Commit

Permalink
Fixed a bug where non-alphabetical bag sorts would shift around when …
Browse files Browse the repository at this point in the history
…selling items.
  • Loading branch information
Cidan committed Sep 2, 2024
1 parent d2022dc commit 168955a
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions views/gridview.lua
Original file line number Diff line number Diff line change
Expand Up @@ -347,8 +347,10 @@ local function GridView(view, ctx, bag, slotInfo, callback)
end

-- Sort the sections.
view.content.maxCellWidth = sizeInfo.columnCount
view.content:Sort(sort:GetSectionSortFunction(bag.kind, const.BAG_VIEW.SECTION_GRID))
if ctx:GetBool('wipe') then
view.content.maxCellWidth = sizeInfo.columnCount
view.content:Sort(sort:GetSectionSortFunction(bag.kind, const.BAG_VIEW.SECTION_GRID))
end

-- Get the free slots section and add the free slots to it.
local freeSlotsSection = view:GetOrCreateSection(ctx, L:G("Free Space"))
Expand Down

0 comments on commit 168955a

Please sign in to comment.