2
0
mirror of https://github.com/koreader/koreader synced 2024-11-10 01:10:34 +00:00

Teminal emulator: fix translatable, fix potential crash (#8756)

This commit is contained in:
zwim 2022-01-31 19:14:29 +01:00 committed by GitHub
parent f0197423ad
commit 8cff5f88b0
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 2 additions and 2 deletions

View File

@ -443,7 +443,7 @@ Aliases (shortcuts) to frequently used commands can be placed in:
},
{
text_func = function()
local state = self.is_shell_open and "running" or "not running"
local state = self.is_shell_open and _("running") or _("not running")
return T(_("Open terminal session (%1)"), state)
end,
callback = function(touchmenu_instance)

View File

@ -252,7 +252,7 @@ function TermInputText:_helperVT52VT100(cmd, mode, param1, param2, param3)
self.scroll_region_bottom = nil
end
if self.scroll_region_bottom and param1 < self.maxr and param1 <= param2 then
if self.scroll_region_bottom and param1 < self.maxr and param1 <= param2 and param1 > 0 then
self.scroll_region_top = param1
self.scroll_region_line = 1
else