-
This commit is contained in:
@@ -199,8 +199,8 @@ if JS then
|
|||||||
))
|
))
|
||||||
end
|
end
|
||||||
|
|
||||||
|
local _clipboardBuffer=''
|
||||||
love.system.getClipboardText = function ()
|
love.system.getClipboardText = function ()
|
||||||
local res=''
|
|
||||||
JS.newPromiseRequest(
|
JS.newPromiseRequest(
|
||||||
JS.stringFunc(
|
JS.stringFunc(
|
||||||
[[
|
[[
|
||||||
@@ -213,12 +213,12 @@ if JS then
|
|||||||
});
|
});
|
||||||
]]
|
]]
|
||||||
),
|
),
|
||||||
function(data) res=data end,
|
function(data) _clipboardBuffer=data end,
|
||||||
function(id, error) print(id, error) end,
|
function(id, error) print(id, error) end,
|
||||||
3,
|
3,
|
||||||
'getClipboardText'
|
'getClipboardText'
|
||||||
)
|
)
|
||||||
return res
|
return _clipboardBuffer
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user