From aadb81eb4831c968daf14e1c20845c9810bb5f6e Mon Sep 17 00:00:00 2001 From: Frans de Jonge Date: Fri, 16 Feb 2018 21:44:10 +0100 Subject: [PATCH] [feat] Add Android clipboard definition (#3479) References https://github.com/koreader/koreader/issues/3441 --- frontend/device/android/device.lua | 10 ++++++++++ platform/android/luajit-launcher | 2 +- 2 files changed, 11 insertions(+), 1 deletion(-) diff --git a/frontend/device/android/device.lua b/frontend/device/android/device.lua index b1af3e6ea..69fd2421c 100644 --- a/frontend/device/android/device.lua +++ b/frontend/device/android/device.lua @@ -14,6 +14,7 @@ local Device = Generic:new{ hasFrontlight = yes, firmware_rev = "none", display_dpi = android.lib.AConfiguration_getDensity(android.app.config), + hasClipboard = yes, hasColorScreen = yes, } @@ -33,6 +34,15 @@ function Device:init() this.device.screen:refreshFull() end end, + hasClipboardText = function() + return android.hasClipboardText() + end, + getClipboardText = function() + return android.getClipboardText() + end, + setClipboardText = function(text) + return android.setClipboardText(text) + end, } -- check if we have a keyboard diff --git a/platform/android/luajit-launcher b/platform/android/luajit-launcher index 41dd31148..e30398701 160000 --- a/platform/android/luajit-launcher +++ b/platform/android/luajit-launcher @@ -1 +1 @@ -Subproject commit 41dd311483abffe5f3738224b7d93b5b2b5e9cd2 +Subproject commit e303987017558fb37ea4da6889fd1ab6315283cf