From 6e4596fe8759a32b64d22abae60f043fa9fe68a5 Mon Sep 17 00:00:00 2001
From: Nils Schneider
Date: Sun, 9 Feb 2014 23:17:50 +0100
Subject: [PATCH] gluon-luci-admin: remove translation support
We'll have to revisit translations at a later point after configmode and
expertmode have matured. Texts in this package were pretty inconsistent
anyway so there is no point in keeping translations for random text
fragments.
---
.../lib/lua/luci/controller/admin/index.lua | 6 +--
.../lib/lua/luci/controller/admin/system.lua | 8 ++--
.../lib/lua/luci/model/cbi/admin/passwd.lua | 16 ++++----
.../lib/lua/luci/view/admin/applyreboot.htm | 8 ++--
.../usr/lib/lua/luci/view/admin/backup.htm | 12 +++---
.../usr/lib/lua/luci/view/admin/index.htm | 2 +-
.../usr/lib/lua/luci/view/admin/reboot.htm | 12 +++---
.../usr/lib/lua/luci/view/admin/upgrade.htm | 38 +++++++++----------
8 files changed, 51 insertions(+), 51 deletions(-)
diff --git a/package/gluon-luci-admin/files/usr/lib/lua/luci/controller/admin/index.lua b/package/gluon-luci-admin/files/usr/lib/lua/luci/controller/admin/index.lua
index fb5000af..a39fc73a 100644
--- a/package/gluon-luci-admin/files/usr/lib/lua/luci/controller/admin/index.lua
+++ b/package/gluon-luci-admin/files/usr/lib/lua/luci/controller/admin/index.lua
@@ -30,7 +30,7 @@ function index()
root.index = true
end
- local page = entry({"admin"}, alias("admin", "index"), _("Expertmode"), 10)
+ local page = entry({"admin"}, alias("admin", "index"), "Expertmode", 10)
page.sysauth = "root"
if configmode then
-- force root to be logged in when running in configmode
@@ -40,10 +40,10 @@ function index()
end
page.index = true
- entry({"admin", "index"}, form("admin/index"), _("Overview"), 1).ignoreindex = true
+ entry({"admin", "index"}, form("admin/index"), "Overview", 1).ignoreindex = true
if not configmode then
- entry({"admin", "logout"}, call("action_logout"), _("Logout"))
+ entry({"admin", "logout"}, call("action_logout"), "Logout")
end
end
diff --git a/package/gluon-luci-admin/files/usr/lib/lua/luci/controller/admin/system.lua b/package/gluon-luci-admin/files/usr/lib/lua/luci/controller/admin/system.lua
index 457f1dde..1ca546a3 100644
--- a/package/gluon-luci-admin/files/usr/lib/lua/luci/controller/admin/system.lua
+++ b/package/gluon-luci-admin/files/usr/lib/lua/luci/controller/admin/system.lua
@@ -16,10 +16,10 @@ $Id$
module("luci.controller.admin.system", package.seeall)
function index()
- entry({"admin", "passwd"}, cbi("admin/passwd"), _("Admin Password"), 10)
- entry({"admin", "backup"}, call("action_backup"), _("Backup / Restore"), 80)
- entry({"admin", "upgrade"}, call("action_upgrade"), _("Flash Firmware"), 90)
- entry({"admin", "reboot"}, call("action_reboot"), _("Reboot"), 100)
+ entry({"admin", "passwd"}, cbi("admin/passwd"), "Admin Password", 10)
+ entry({"admin", "backup"}, call("action_backup"), "Backup / Restore", 80)
+ entry({"admin", "upgrade"}, call("action_upgrade"), "Flash Firmware", 90)
+ entry({"admin", "reboot"}, call("action_reboot"), "Reboot", 100)
end
function action_backup()
diff --git a/package/gluon-luci-admin/files/usr/lib/lua/luci/model/cbi/admin/passwd.lua b/package/gluon-luci-admin/files/usr/lib/lua/luci/model/cbi/admin/passwd.lua
index 9f1ba873..5658ce9f 100644
--- a/package/gluon-luci-admin/files/usr/lib/lua/luci/model/cbi/admin/passwd.lua
+++ b/package/gluon-luci-admin/files/usr/lib/lua/luci/model/cbi/admin/passwd.lua
@@ -20,16 +20,16 @@ local m, s, pw1, pw2
m = Map("system", "Passwort & SSH Keys")
-s = m:section(TypedSection, translate("Router Password"),
- translate("Changes the administrator password for accessing the device"))
+s = m:section(TypedSection, "Router Password",
+ "Changes the administrator password for accessing the device")
s.addremove = false
s.anonymous = true
-pw1 = s:option(Value, "pw1", translate("Password"))
+pw1 = s:option(Value, "pw1", "Password")
pw1.password = true
-pw2 = s:option(Value, "pw2", translate("Confirmation"))
+pw2 = s:option(Value, "pw2", "Confirmation")
pw2.password = true
function s.cfgsections()
@@ -43,19 +43,19 @@ function m.on_commit(map)
if v1 and v2 and #v1 > 0 and #v2 > 0 then
if v1 == v2 then
if luci.sys.user.setpasswd(luci.dispatcher.context.authuser, v1) == 0 then
- m.message = translate("Password successfully changed!")
+ m.message = "Password successfully changed!"
else
- m.message = translate("Unknown Error, password not changed!")
+ m.message = "Unknown Error, password not changed!"
end
else
- m.message = translate("Given password confirmation did not match, password not changed!")
+ m.message = "Given password confirmation did not match, password not changed!"
end
end
end
if fs.access("/etc/config/dropbear") then
s = m:section(TypedSection, "_keys", "SSH Keys",
- translate("Here you can paste public SSH-Keys (one per line) for SSH public-key authentication."))
+ "Here you can paste public SSH-Keys (one per line) for SSH public-key authentication.")
s.addremove = false
s.anonymous = true
diff --git a/package/gluon-luci-admin/files/usr/lib/lua/luci/view/admin/applyreboot.htm b/package/gluon-luci-admin/files/usr/lib/lua/luci/view/admin/applyreboot.htm
index 8ff7118c..46fa4b6d 100644
--- a/package/gluon-luci-admin/files/usr/lib/lua/luci/view/admin/applyreboot.htm
+++ b/package/gluon-luci-admin/files/usr/lib/lua/luci/view/admin/applyreboot.htm
@@ -13,9 +13,9 @@ $Id$
-%>
<%+header%>
-
+
-<% if msg then %><%=msg%><% else %><%:Changes applied.%><% end %>
-<%:Please wait: Device rebooting...%>
+<% if msg then %><%=msg%><% else %>Changes applied.<% end %>
+Please wait: Device rebooting...
-<%+footer%>
\ No newline at end of file
+<%+footer%>
diff --git a/package/gluon-luci-admin/files/usr/lib/lua/luci/view/admin/backup.htm b/package/gluon-luci-admin/files/usr/lib/lua/luci/view/admin/backup.htm
index 167419da..5299b013 100644
--- a/package/gluon-luci-admin/files/usr/lib/lua/luci/view/admin/backup.htm
+++ b/package/gluon-luci-admin/files/usr/lib/lua/luci/view/admin/backup.htm
@@ -13,14 +13,14 @@ $Id$
-%>
<%+header%>
-
-<%:Here you can backup and restore your configuration and - if possible - reset this device to the default settings.%>
+
+Here you can backup and restore your configuration and - if possible - reset this device to the default settings.
@@ -28,12 +28,12 @@ $Id$
<%+footer%>
diff --git a/package/gluon-luci-admin/files/usr/lib/lua/luci/view/admin/index.htm b/package/gluon-luci-admin/files/usr/lib/lua/luci/view/admin/index.htm
index c1656a7e..c789bb88 100644
--- a/package/gluon-luci-admin/files/usr/lib/lua/luci/view/admin/index.htm
+++ b/package/gluon-luci-admin/files/usr/lib/lua/luci/view/admin/index.htm
@@ -1,4 +1,4 @@
-
+
Dies ist der Experten-Modus deines Freifunkknotens.
Hier kannst du weitere Einstellungen vornehmen, Firmware Upates
einspielen und auch vieles kaputt machen.
diff --git a/package/gluon-luci-admin/files/usr/lib/lua/luci/view/admin/reboot.htm b/package/gluon-luci-admin/files/usr/lib/lua/luci/view/admin/reboot.htm
index 91699e3a..2eaf6d70 100644
--- a/package/gluon-luci-admin/files/usr/lib/lua/luci/view/admin/reboot.htm
+++ b/package/gluon-luci-admin/files/usr/lib/lua/luci/view/admin/reboot.htm
@@ -13,19 +13,19 @@ $Id$
-%>
<%+header%>
-
-<%:Reboots the operating system of your device%>
+
+Reboots the operating system of your device
<%-
local c = require("luci.model.uci").cursor():changes()
if c and next(c) then
-%>
- <%:Warning: There are unsaved changes that will be lost while rebooting!%>
+ Warning: There are unsaved changes that will be lost while rebooting!
<%-
end
if not reboot then
-%>
-<%:Perform reboot%>
+Perform reboot
<%- else -%>
-<%:Please wait: Device rebooting...%>
+Please wait: Device rebooting...
<%- end -%>
-<%+footer%>
\ No newline at end of file
+<%+footer%>
diff --git a/package/gluon-luci-admin/files/usr/lib/lua/luci/view/admin/upgrade.htm b/package/gluon-luci-admin/files/usr/lib/lua/luci/view/admin/upgrade.htm
index 3d75b415..3380dc63 100644
--- a/package/gluon-luci-admin/files/usr/lib/lua/luci/view/admin/upgrade.htm
+++ b/package/gluon-luci-admin/files/usr/lib/lua/luci/view/admin/upgrade.htm
@@ -15,58 +15,58 @@ $Id$
<%+header%>
-
+
<% if step == 1 then %>
<% if supported then %>
- <%:Firmware image%>:
+ Firmware image:
<% if keepavail then -%>
- <%:Keep configuration files%>
+ Keep configuration files
<% end -%>
-
+
<% else %>
- <%_ Sorry.
+
Sorry.
OpenWrt does not support a system upgrade on this platform.
- You need to manually flash your device. %>
+ You need to manually flash your device.
<% end %>
<% elseif step == 2 then %>
- <%_ The flash image was uploaded.
+ The flash image was uploaded.
Below is the checksum and file size listed,
compare them with the original file to ensure data integrity.
- Click "Proceed" below to start the flash procedure. %>
+ Click "Proceed" below to start the flash procedure.
<% if flashsize > 0 and filesize > flashsize then %>
-
<%:It appears that you try to
+
It appears that you try to
flash an image that does not fit into the flash memory, please verify
- the image file! %>
+ the image file!
<% end %>
- <%:Checksum%>: <%=checksum%>
- <%:Size%>: <%
+ Checksum: <%=checksum%>
+ Size: <%
local w = require "luci.tools.webadmin"
write(w.byte_format(filesize))
@@ -83,20 +83,20 @@ $Id$
<% elseif step == 3 then %>
- <%_ The system is flashing now.
+
The system is flashing now.
DO NOT POWER OFF THE DEVICE!
Wait a few minutes until you try to reconnect.
It might be necessary to renew the address of your computer to reach the device
- again, depending on your settings. %>
+ again, depending on your settings.
<% end %>