mirror of
https://github.com/koreader/koreader.git
synced 2025-08-10 00:52:38 +00:00
InputContainer: Fall cleanup ;).
Get rid of the doc & seqtext fields, as they are not actually used (nor are they particularly useful, the event handler's name should be pretty self-explanatory). Also, tweak the key_events documentation to highlight the quirks of the API, especially as far as array nesting is involved... Random drive-by cleanup of the declarations of key_events & ges_events to re-use the existing instance object (now that we know they're sane ;p) for tables with a single member (less GC pressure).
This commit is contained in:
@@ -95,48 +95,48 @@ function ReaderZooming:init()
|
||||
self.key_events = {
|
||||
ZoomIn = {
|
||||
{ "Shift", Input.group.PgFwd },
|
||||
doc = "zoom in",
|
||||
event = "Zoom", args = "in"
|
||||
event = "Zoom",
|
||||
args = "in",
|
||||
},
|
||||
ZoomOut = {
|
||||
{ "Shift", Input.group.PgBack },
|
||||
doc = "zoom out",
|
||||
event = "Zoom", args = "out"
|
||||
event = "Zoom",
|
||||
args = "out",
|
||||
},
|
||||
ZoomToFitPage = {
|
||||
{ "A" },
|
||||
doc = "zoom to fit page",
|
||||
event = "SetZoomMode", args = "page"
|
||||
event = "SetZoomMode",
|
||||
args = "page",
|
||||
},
|
||||
ZoomToFitContent = {
|
||||
{ "Shift", "A" },
|
||||
doc = "zoom to fit content",
|
||||
event = "SetZoomMode", args = "content"
|
||||
event = "SetZoomMode",
|
||||
args = "content",
|
||||
},
|
||||
ZoomToFitPageWidth = {
|
||||
{ "S" },
|
||||
doc = "zoom to fit page width",
|
||||
event = "SetZoomMode", args = "pagewidth"
|
||||
event = "SetZoomMode",
|
||||
args = "pagewidth",
|
||||
},
|
||||
ZoomToFitContentWidth = {
|
||||
{ "Shift", "S" },
|
||||
doc = "zoom to fit content width",
|
||||
event = "SetZoomMode", args = "contentwidth"
|
||||
event = "SetZoomMode",
|
||||
args = "contentwidth",
|
||||
},
|
||||
ZoomToFitPageHeight = {
|
||||
{ "D" },
|
||||
doc = "zoom to fit page height",
|
||||
event = "SetZoomMode", args = "pageheight"
|
||||
event = "SetZoomMode",
|
||||
args = "pageheight",
|
||||
},
|
||||
ZoomToFitContentHeight = {
|
||||
{ "Shift", "D" },
|
||||
doc = "zoom to fit content height",
|
||||
event = "SetZoomMode", args = "contentheight"
|
||||
event = "SetZoomMode",
|
||||
args = "contentheight",
|
||||
},
|
||||
ZoomManual = {
|
||||
{ "Shift", "M" },
|
||||
doc = "manual zoom mode",
|
||||
event = "SetZoomMode", args = "manual"
|
||||
event = "SetZoomMode",
|
||||
args = "manual",
|
||||
},
|
||||
}
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user