Skip to content

Commit

Permalink
UX and language fixes
Browse files Browse the repository at this point in the history
* lang: changed `...` in CloudStorage to real ellipses
* chore: reordered requires in CloudStorage per coding style
* UX: switched "Close" and "Stay alive" in KeepAlive per UX style
* lang: improved message in CloudStorage
  • Loading branch information
Frenzie committed Apr 6, 2017
1 parent 1461574 commit fa5f84d
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 16 deletions.
23 changes: 12 additions & 11 deletions frontend/apps/cloudstorage/cloudstorage.lua
Original file line number Diff line number Diff line change
@@ -1,16 +1,17 @@
local UIManager = require("ui/uimanager")
local Screen = require("device").screen
local _ = require("gettext")
local Menu = require("ui/widget/menu")
local InfoMessage = require("ui/widget/infomessage")
local ButtonDialog = require("ui/widget/buttondialog")
local DropBox = require("frontend/apps/cloudstorage/dropbox")
local LuaSettings = require("luasettings")
local ButtonDialogTitle = require("ui/widget/buttondialogtitle")
local ConfirmBox = require("ui/widget/confirmbox")
local DataStorage = require("datastorage")
local DropBox = require("frontend/apps/cloudstorage/dropbox")
local InfoMessage = require("ui/widget/infomessage")
local Ftp = require("frontend/apps/cloudstorage/ftp")
local ConfirmBox = require("ui/widget/confirmbox")
local Menu = require("ui/widget/menu")
local LuaSettings = require("luasettings")
local Screen = require("device").screen
local UIManager = require("ui/uimanager")
local _ = require("gettext")
local lfs = require("libs/libkoreader-lfs")
local ButtonDialogTitle = require("ui/widget/buttondialogtitle")


local CloudStorage = Menu:extend{
cloud_servers = {
Expand Down Expand Up @@ -181,7 +182,7 @@ function CloudStorage:cloudFile(item, path)
end)
UIManager:close(self.download_dialog)
UIManager:show(InfoMessage:new{
text = _("Downloading may take several minutes..."),
text = _("Downloading may take several minutes"),
timeout = 1,
})
elseif self.type == "ftp" then
Expand All @@ -193,7 +194,7 @@ function CloudStorage:cloudFile(item, path)
end)
UIManager:close(self.download_dialog)
UIManager:show(InfoMessage:new{
text = _("Downloading may take several minutes..."),
text = _("Downloading may take several minutes"),
timeout = 1,
})
end
Expand Down
10 changes: 5 additions & 5 deletions plugins/keepalive.koplugin/main.lua
Original file line number Diff line number Diff line change
Expand Up @@ -15,14 +15,14 @@ local enable

local function showConfirmBox()
UIManager:show(ConfirmBox:new{
text = _("The system won't sleep when this message is showing.\nPress \"Stay alive\" if you prefer to keep system on even after closing this notification. *It will drain the battery.*\n\nIf for any reasons KOReader died before \"Close\" is pressed, please start and close KeepAlive plugin again to ensure settings are reset."),
ok_text = _("Close"),
ok_callback = function()
text = _("The system won't sleep while this message is showing.\n\nPress \"Stay alive\" if you prefer to keep the system on even after closing this notification. *This will drain the battery*.\n\nIf KOReader terminates before \"Close\" is pressed, please start and close the KeepAlive plugin again to ensure settings are reset."),
cancel_text = _("Close"),
cancel_callback = function()
disable()
menuItem.checked =false
end,
cancel_text = _("Stay alive"),
cancel_callback = function()
ok_text = _("Stay alive"),
ok_callback = function()
menuItem.checked = true
end,
})
Expand Down

0 comments on commit fa5f84d

Please sign in to comment.