mirror of
https://github.com/koreader/koreader.git
synced 2025-08-10 00:52:38 +00:00
added clearSelection
Conflicts: unireader.lua
This commit is contained in:
committed by
Qingping Hou
parent
bc4d2e7a49
commit
f2933a32c0
8
cre.cpp
8
cre.cpp
@@ -484,6 +484,13 @@ static int gotoLink(lua_State *L) {
|
||||
return 0;
|
||||
}
|
||||
|
||||
static int clearSelection(lua_State *L) {
|
||||
CreDocument *doc = (CreDocument*) luaL_checkudata(L, 1, "credocument");
|
||||
|
||||
doc->text_view->clearSelection();
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
static int drawCurrentPage(lua_State *L) {
|
||||
CreDocument *doc = (CreDocument*) luaL_checkudata(L, 1, "credocument");
|
||||
@@ -634,6 +641,7 @@ static const struct luaL_Reg credocument_meth[] = {
|
||||
{"findText", findText},
|
||||
{"getPageLinks", getPageLinks},
|
||||
{"gotoLink", gotoLink},
|
||||
{"clearSelection", clearSelection},
|
||||
{"close", closeDocument},
|
||||
{"__gc", closeDocument},
|
||||
{NULL, NULL}
|
||||
|
||||
Reference in New Issue
Block a user