mirror of
https://github.com/koreader/koreader.git
synced 2025-08-10 00:52:38 +00:00
Koreader Ubuntu-touch port
Currently only tested on Ubuntu-touch emulator with framework ubuntu-sdk-14.10 for armhf. The ubuntu-touch port is binary compatible with the Kobo port major changes in this PR are: 1. rename the emulator device to sdl device since both the emulator and the ubuntu-touch target use libsdl to handle input/output. 2. ubuntu-touch app has no write access to the installation dir so all write-outs should be in a seperate dir definded in `datastorage`.
This commit is contained in:
@@ -1,6 +1,7 @@
|
||||
local InputContainer = require("ui/widget/container/inputcontainer")
|
||||
local DictQuickLookup = require("ui/widget/dictquicklookup")
|
||||
local InfoMessage = require("ui/widget/infomessage")
|
||||
local DataStorage = require("datastorage")
|
||||
local UIManager = require("ui/uimanager")
|
||||
local Screen = require("device").screen
|
||||
local Device = require("device")
|
||||
@@ -15,11 +16,8 @@ local ReaderDictionary = InputContainer:new{
|
||||
|
||||
function ReaderDictionary:init()
|
||||
self.ui.menu:registerToMainMenu(self)
|
||||
if Device:isAndroid() then
|
||||
self.data_dir = "/sdcard/koreader/data/dict"
|
||||
else
|
||||
self.data_dir = os.getenv("STARDICT_DATA_DIR") or "data/dict"
|
||||
end
|
||||
self.data_dir = os.getenv("STARDICT_DATA_DIR") or
|
||||
DataStorage:getDataDir() .. "/data/dict"
|
||||
end
|
||||
|
||||
function ReaderDictionary:addToMainMenu(tab_item_table)
|
||||
|
||||
Reference in New Issue
Block a user