mirror of
https://github.com/koreader/koreader.git
synced 2025-08-10 00:52:38 +00:00
Statistics plugin: reorder Reset menu items
This commit is contained in:
@@ -1897,15 +1897,7 @@ end
|
||||
function ReaderStatistics:genResetBookSubItemTable()
|
||||
local sub_item_table = {}
|
||||
table.insert(sub_item_table, {
|
||||
text = _("Reset statistics per book"),
|
||||
keep_menu_open = true,
|
||||
callback = function()
|
||||
self:resetBook()
|
||||
end,
|
||||
separator = true,
|
||||
})
|
||||
table.insert(sub_item_table, {
|
||||
text = _("Reset statistics for current book"),
|
||||
text = _("Reset statistics for the current book"),
|
||||
keep_menu_open = true,
|
||||
callback = function()
|
||||
self:resetCurrentBook()
|
||||
@@ -1913,6 +1905,14 @@ function ReaderStatistics:genResetBookSubItemTable()
|
||||
enabled_func = function() return not self:isDocless() and self.is_enabled and self.id_curr_book end,
|
||||
separator = true,
|
||||
})
|
||||
table.insert(sub_item_table, {
|
||||
text = _("Reset statistics per book"),
|
||||
keep_menu_open = true,
|
||||
callback = function()
|
||||
self:resetBook()
|
||||
end,
|
||||
separator = true,
|
||||
})
|
||||
local reset_minutes = { 1, 5, 15, 30, 60 }
|
||||
for _, minutes in ipairs(reset_minutes) do
|
||||
local text = T(N_("Reset stats for books read for < 1 m",
|
||||
|
||||
Reference in New Issue
Block a user