fix #2054 by removing ticks max limitation

pull/2087/head
chrox 8 years ago
parent cf3c91d92e
commit ad88192d85

@ -38,7 +38,6 @@ local ReaderFooter = InputContainer:new{
pageno = nil,
pages = nil,
toc_level = 0,
max_ticks = 100,
progress_percentage = 0.0,
progress_text = nil,
text_font_face = "ffont",
@ -327,9 +326,7 @@ function ReaderFooter:_updateFooterText()
local max_level = self.ui.toc:getMaxDepth()
for i = 0, -max_level, -1 do
local ticks = self.ui.toc:getTocTicks(i)
if #ticks < self.max_ticks then
table.insert(ticks_candidates, ticks)
end
table.insert(ticks_candidates, ticks)
end
-- find the finest toc ticks by sorting out the largest one
table.sort(ticks_candidates, function(a, b) return #a > #b end)

Loading…
Cancel
Save