mirror of https://github.com/kepler155c/opus
apparently read was added to fs.open "r" mode in 2017
This commit is contained in:
parent
1e675a2e35
commit
424fff7842
|
@ -77,6 +77,10 @@ function ramfs.open(node, fn, fl)
|
||||||
local ctr = 0
|
local ctr = 0
|
||||||
local lines
|
local lines
|
||||||
return {
|
return {
|
||||||
|
read = function()
|
||||||
|
ctr = ctr + 1
|
||||||
|
return node.contents:sub(ctr, ctr)
|
||||||
|
end,
|
||||||
readLine = function()
|
readLine = function()
|
||||||
if not lines then
|
if not lines then
|
||||||
lines = Util.split(node.contents)
|
lines = Util.split(node.contents)
|
||||||
|
|
|
@ -74,6 +74,10 @@ function urlfs.open(node, fn, fl)
|
||||||
|
|
||||||
if fl == 'r' then
|
if fl == 'r' then
|
||||||
return {
|
return {
|
||||||
|
read = function()
|
||||||
|
ctr = ctr + 1
|
||||||
|
return c:sub(ctr, ctr)
|
||||||
|
end,
|
||||||
readLine = function()
|
readLine = function()
|
||||||
if not lines then
|
if not lines then
|
||||||
lines = Util.split(c)
|
lines = Util.split(c)
|
||||||
|
|
|
@ -39,7 +39,7 @@ function Transition.expandUp(args)
|
||||||
local easing = args.easing or 'linear'
|
local easing = args.easing or 'linear'
|
||||||
local pos = { y = args.ey + 1 }
|
local pos = { y = args.ey + 1 }
|
||||||
local tween = Tween.new(ticks, pos, { y = args.y }, easing)
|
local tween = Tween.new(ticks, pos, { y = args.y }, easing)
|
||||||
_syslog(args)
|
|
||||||
args.canvas:move(args.x, pos.y)
|
args.canvas:move(args.x, pos.y)
|
||||||
|
|
||||||
return function()
|
return function()
|
||||||
|
|
Loading…
Reference in New Issue