mirror of https://github.com/koreader/koreader
add dummy device & rename runtimectl:setDevice to runtimectl:init
parent
8513778990
commit
855c8c2569
@ -0,0 +1,26 @@
|
||||
local Generic = require("device/generic/device")
|
||||
local logger = require("logger")
|
||||
|
||||
local function yes() return true end
|
||||
local function no() return false end
|
||||
|
||||
local Device = Generic:new{
|
||||
model = "dummy",
|
||||
hasKeyboard = no,
|
||||
hasKeys = no,
|
||||
isTouchDevice = no,
|
||||
needsScreenRefreshAfterResume = no,
|
||||
hasColorScreen = yes,
|
||||
hasEinkScreen = no,
|
||||
}
|
||||
|
||||
function Device:init()
|
||||
self.screen = require("ffi/framebuffer_SDL2_0"):new{
|
||||
dummy = true,
|
||||
device = self,
|
||||
debug = logger.dbg,
|
||||
}
|
||||
Generic.init(self)
|
||||
end
|
||||
|
||||
return Device
|
Loading…
Reference in New Issue