common_settings: migrate document menu to menu_order ordering

This is necessary in order to allow the language support module to be
added to the menu outside of the common_settings menu table definition.

Signed-off-by: Aleksa Sarai <cyphar@cyphar.com>
pull/8364/head
Aleksa Sarai 3 years ago committed by Frans de Jonge
parent dca65a793e
commit da70fe9de1

@ -513,8 +513,10 @@ end
common_settings.document = {
text = _("Document"),
sub_item_table = {
{
-- submenus are filled by menu_order
}
common_settings.document_auto_save = {
text_func = function()
local interval = G_reader_settings:readSetting("auto_save_settings_interval_minutes")
local s_interval
@ -539,8 +541,9 @@ common_settings.document = {
end,
} or nil,
},
},
{
}
common_settings.document_save = {
text = _("Save document (write highlights into PDF)"),
sub_item_table = {
{
@ -574,8 +577,9 @@ common_settings.document = {
end,
},
},
},
{
}
common_settings.document_end_action = {
text = _("End of document action"),
sub_item_table = {
{
@ -674,9 +678,8 @@ common_settings.document = {
end,
},
}
},
},
}
common_settings.language = Language:getLangMenuTable()
common_settings.screenshot = {

@ -35,6 +35,11 @@ local order = {
"device",
-- end common settings
},
document = {
"document_auto_save",
"document_save",
"document_end_action",
},
device = {
"keyboard_layout",
"time",

@ -72,6 +72,11 @@ local order = {
"----------------------------",
"status_bar",
},
document = {
"document_auto_save",
"document_save",
"document_end_action",
},
device = {
"keyboard_layout",
"time",

Loading…
Cancel
Save