From: David ‘Bombe’ Roden Date: Sat, 23 Oct 2010 20:27:41 +0000 (+0200) Subject: Add “about” page. X-Git-Tag: 0.1-RC1~56 X-Git-Url: https://git.pterodactylus.net/?p=Sone.git;a=commitdiff_plain;h=814228fa94dc3657eb57b886e6812f442dce8754 Add “about” page. --- diff --git a/src/main/java/net/pterodactylus/sone/web/WebInterface.java b/src/main/java/net/pterodactylus/sone/web/WebInterface.java index f9d6f64..f681ce7 100644 --- a/src/main/java/net/pterodactylus/sone/web/WebInterface.java +++ b/src/main/java/net/pterodactylus/sone/web/WebInterface.java @@ -214,6 +214,7 @@ public class WebInterface extends AbstractService { Template deleteSoneTemplate = templateFactory.createTemplate(createReader("/templates/deleteSone.html")); Template noPermissionTemplate = templateFactory.createTemplate(createReader("/templates/noPermission.html")); Template logoutTemplate = templateFactory.createTemplate(createReader("/templates/logout.html")); + Template aboutTemplate = templateFactory.createTemplate(createReader("/templates/about.html")); PageToadletFactory pageToadletFactory = new PageToadletFactory(sonePlugin.pluginRespirator().getHLSimpleClient(), "/Sone/"); pageToadlets.add(pageToadletFactory.createPageToadlet(new IndexPage(indexTemplate, this), "Index")); @@ -238,6 +239,7 @@ public class WebInterface extends AbstractService { pageToadlets.add(pageToadletFactory.createPageToadlet(new DeleteSonePage(deleteSoneTemplate, this), "DeleteSone")); pageToadlets.add(pageToadletFactory.createPageToadlet(new LoginPage(loginTemplate, this), "Login")); pageToadlets.add(pageToadletFactory.createPageToadlet(new LogoutPage(logoutTemplate, this), "Logout")); + pageToadlets.add(pageToadletFactory.createPageToadlet(new SoneTemplatePage("about.html", aboutTemplate, "Page.About.Title", this), "About")); pageToadlets.add(pageToadletFactory.createPageToadlet(new SoneTemplatePage("noPermission.html", noPermissionTemplate, "Page.NoPermission.Title", this))); pageToadlets.add(pageToadletFactory.createPageToadlet(new StaticPage("css/", "/static/css/", "text/css"))); pageToadlets.add(pageToadletFactory.createPageToadlet(new StaticPage("javascript/", "/static/javascript/", "text/javascript"))); diff --git a/src/main/resources/i18n/sone.en.properties b/src/main/resources/i18n/sone.en.properties index 3235622..00ad9ff 100644 --- a/src/main/resources/i18n/sone.en.properties +++ b/src/main/resources/i18n/sone.en.properties @@ -14,6 +14,11 @@ Navigation.Menu.Item.DeleteSone.Name=Delete Sone Navigation.Menu.Item.DeleteSone.Tooltip=Deletes the current Sone Navigation.Menu.Item.Logout.Name=Logout Navigation.Menu.Item.Logout.Tooltip=Logs you out of the current Sone +Navigation.Menu.Item.About.Name=About +Navigation.Menu.Item.About.Tooltip=Information about Sone + +Page.About.Title=About - Sone +Page.About.Page.Title=About Page.Login.Title=Login - Sone Page.Login.Page.Title=Login diff --git a/src/main/resources/templates/about.html b/src/main/resources/templates/about.html new file mode 100644 index 0000000..c401b02 --- /dev/null +++ b/src/main/resources/templates/about.html @@ -0,0 +1,27 @@ +<%include include/head.html> + +

<%= Page.About.Page.Title|l10n|html>

+ +

Sone – The Freenet Social Network Plugin, © 2010 by David ‘Bombe’ Roden.

+ +

+ This program is free software: you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation, either version 3 of the License, or + (at your option) any later version. +

+ +

+ This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. +

+ +

+ You should have received a copy of the GNU General Public License + along with this program. If not, see + www.gnu.org/licenses. +

+ +<%include include/tail.html>