summaryrefslogtreecommitdiff
path: root/pages/setup.ecpp
diff options
context:
space:
mode:
Diffstat (limited to 'pages/setup.ecpp')
-rw-r--r--pages/setup.ecpp30
1 files changed, 30 insertions, 0 deletions
diff --git a/pages/setup.ecpp b/pages/setup.ecpp
index b099c0f..43c0de8 100644
--- a/pages/setup.ecpp
+++ b/pages/setup.ecpp
@@ -1,4 +1,5 @@
<%pre>
+#include <vdr/tools.h>
#include "setup.h"
#include "tools.h"
@@ -13,6 +14,7 @@ using namespace std;
string pass;
string times;
string startscreen;
+ string theme;
string localnetmask;
</%args>
<%session scope="global">
@@ -37,6 +39,7 @@ if (!logged_in && LiveSetup().UseAuth()) return reply.redirect("login.html");
}
LiveSetup().SetTimes(times);
LiveSetup().SetStartScreen(startscreen);
+ LiveSetup().SetTheme(theme);
LiveSetup().SaveSetup();
}
pageTitle = tr("Setup");
@@ -50,6 +53,7 @@ if (!logged_in && LiveSetup().UseAuth()) return reply.redirect("login.html");
useauth = LiveSetup().GetUseAuth();
times = LiveSetup().GetTimes();
startscreen = LiveSetup().GetStartScreen();
+ theme = LiveSetup().GetTheme();
localnetmask = LiveSetup().GetLocalNetMask();
</%cpp>
<& pageelems.doc_type &>
@@ -130,6 +134,32 @@ if (!logged_in && LiveSetup().UseAuth()) return reply.redirect("login.html");
</tr>
<tr>
<td class="border" style="border-left: 1px solid black"></td>
+ <td class="label"><$ tr("Theme") $>:</td>
+ <td><select name="theme" size="1" id="theme">
+<%cpp>
+{
+ cReadDir d(USRDIR "/themes");
+ struct dirent* e;
+ string parent("..");
+ string current(".");
+ while ((e = d.Next())) {
+ if ((current == e->d_name) || (parent == e->d_name)) {
+ continue;
+ }
+ if (DT_DIR != e->d_type) {
+ continue;
+ }
+</%cpp>
+ <option value="<$ e->d_name $>" <{ SELECTIF(theme == e->d_name) }>><$ e->d_name $></option>
+<%cpp>
+ }
+}
+</%cpp>
+ </select></td>
+ <td class="border" style="border-right: 1px solid black"></td>
+ </tr>
+ <tr>
+ <td class="border" style="border-left: 1px solid black"></td>
<td class="buttonpanel" colspan="2">
<button class="green" type="submit" name="save" onclick="return checksearch();"><$ tr("Save") $></button>
</td>