[Android, UX] Add Device:openLink() implementation (#4824)

Fixes https://github.com/koreader/koreader/issues/4821

Same as https://github.com/koreader/koreader/pull/4822

Thanks to @pazos who implemented the Android backend, see https://github.com/koreader/android-luajit-launcher/pull/133
This commit is contained in:
Frans de Jonge
2019-03-20 17:28:19 +01:00
committed by GitHub
parent b1ed2838c8
commit 2f65fb94ec
2 changed files with 5 additions and 1 deletions

View File

@@ -27,6 +27,10 @@ local Device = Generic:new{
display_dpi = android.lib.AConfiguration_getDensity(android.app.config),
hasClipboard = yes,
hasOTAUpdates = canUpdateApk,
openLink = function(self, link)
if not link or type(link) ~= "string" then return end
return android.openLink(link) == 0
end,
--[[
Disable jit on some modules on android to make koreader on Android more stable.