From 065403a514bbe30ce02634d95c388607e3b33e96 Mon Sep 17 00:00:00 2001 From: Jo-Philipp Wich Date: Thu, 25 Mar 2010 17:05:02 +0000 Subject: [PATCH] luci-0.9: merge r5920-5922 --- .../luci-livestats/luasrc/view/livestats/wireless.htm | 2 +- .../admin-full/luasrc/model/cbi/admin_system/system.lua | 5 ++++- themes/base/htdocs/luci-static/resources/Dropdowns.js | 8 ++++++++ 3 files changed, 13 insertions(+), 2 deletions(-) diff --git a/applications/luci-livestats/luasrc/view/livestats/wireless.htm b/applications/luci-livestats/luasrc/view/livestats/wireless.htm index ca384b2f7..1502e1ed9 100644 --- a/applications/luci-livestats/luasrc/view/livestats/wireless.htm +++ b/applications/luci-livestats/luasrc/view/livestats/wireless.htm @@ -18,7 +18,7 @@ [ function(data) { return parseFloat(data["Signal level"]) - parseFloat(data["Noise level"]); - }, "S/N (dBm)"], + }, "S/N (dB)"], // Graph layout options { drawBackground: false, yAxis: [ 0, 50 ], diff --git a/modules/admin-full/luasrc/model/cbi/admin_system/system.lua b/modules/admin-full/luasrc/model/cbi/admin_system/system.lua index c37e72629..37144fbc4 100644 --- a/modules/admin-full/luasrc/model/cbi/admin_system/system.lua +++ b/modules/admin-full/luasrc/model/cbi/admin_system/system.lua @@ -15,6 +15,7 @@ $Id$ require("luci.sys") require("luci.sys.zoneinfo") require("luci.tools.webadmin") +require("luci.fs") m = Map("system", translate("system"), translate("a_s_desc")) @@ -72,7 +73,9 @@ function tz.write(self, section, value) end AbstractValue.write(self, section, value) - self.map.uci:set("system", section, "timezone", lookup_zone(value) or "GMT0") + local timezone = lookup_zone(value) or "GMT0" + self.map.uci:set("system", section, "timezone", timezone) + luci.fs.writefile("/etc/TZ", timezone .. "\n") end s:option(Value, "log_size", nil, "kiB").optional = true diff --git a/themes/base/htdocs/luci-static/resources/Dropdowns.js b/themes/base/htdocs/luci-static/resources/Dropdowns.js index 8c07a6f2f..a8d12b959 100644 --- a/themes/base/htdocs/luci-static/resources/Dropdowns.js +++ b/themes/base/htdocs/luci-static/resources/Dropdowns.js @@ -187,6 +187,14 @@ function initDropdowns() { } } } + + XHTML1.addEventListener(document, "click", function() { + if (delayHideTimerId) { + clearTimeout(delayHideTimerId); + delayHideTimerId = 0; + delayHide(); + } + }); } if(XHTML1.isDOMSupported()) { -- 2.25.1