Skip to content

Commit

Permalink
Merge pull request #195 from Slivo-fr/bugfix/rollback-gui-height-change
Browse files Browse the repository at this point in the history
Revert "Increase height of display according to the number of bracket…
  • Loading branch information
kakysha authored Mar 19, 2022
2 parents 6513838 + 0b1fe00 commit 6317a35
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions GUI.lua
Original file line number Diff line number Diff line change
Expand Up @@ -100,7 +100,6 @@ function GUI:UpdateTableView()
local buttons = HybridScrollFrame_GetButtons(scroll);
local offset = HybridScrollFrame_GetOffset(scroll);
local brk_delim_inserted = false
local bracketSeparatorButtonDisplayedCount = 0;

for buttonIndex = 1, #buttons do
local button = buttons[buttonIndex];
Expand Down Expand Up @@ -131,8 +130,7 @@ function GUI:UpdateTableView()
button.Background:SetTexture("Interface/Glues/CharacterCreate/CharacterCreateMetalFrameHorizontal")
button.Highlight:SetTexture()
button:Show();
bracketSeparatorButtonDisplayedCount = bracketSeparatorButtonDisplayedCount + 1


elseif (itemIndex <= #rows) then
local name, class, thisWeekHonor, estHonor, lastWeekHonor, standing, RP, rank, last_checked = unpack(rows[itemIndex])
local last_seen, last_seen_human = (GetServerTime() - last_checked), ""
Expand Down Expand Up @@ -206,7 +204,7 @@ function GUI:UpdateTableView()
end

local buttonHeight = scroll.buttonHeight;
local totalHeight = (#rows + bracketSeparatorButtonDisplayedCount) * buttonHeight
local totalHeight = #rows * buttonHeight;
local shownHeight = #buttons * buttonHeight;

HybridScrollFrame_Update(scroll, totalHeight, shownHeight);
Expand Down

0 comments on commit 6317a35

Please sign in to comment.