You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@isis.apache.org by da...@apache.org on 2014/10/26 16:23:25 UTC
[3/3] git commit: ISIS-537: for todoapp, simpleapp: bootstrap themes,
default theme.
ISIS-537: for todoapp, simpleapp: bootstrap themes, default theme.
Project: http://git-wip-us.apache.org/repos/asf/isis/repo
Commit: http://git-wip-us.apache.org/repos/asf/isis/commit/982e1630
Tree: http://git-wip-us.apache.org/repos/asf/isis/tree/982e1630
Diff: http://git-wip-us.apache.org/repos/asf/isis/diff/982e1630
Branch: refs/heads/master
Commit: 982e1630372ee9421920ed3a57d051c1878ca92e
Parents: c02fb76
Author: Dan Haywood <da...@haywood-associates.co.uk>
Authored: Sun Oct 26 15:22:20 2014 +0000
Committer: Dan Haywood <da...@haywood-associates.co.uk>
Committed: Sun Oct 26 15:22:41 2014 +0000
----------------------------------------------------------------------
.../src/main/java/webapp/SimpleApplication.java | 16 +++++++++++++++-
.../main/webapp/WEB-INF/viewer_wicket.properties | 2 +-
.../src/main/java/webapp/ToDoApplication.java | 15 ++++++++++++++-
.../main/webapp/WEB-INF/viewer_wicket.properties | 3 ++-
4 files changed, 32 insertions(+), 4 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/isis/blob/982e1630/example/application/simpleapp/webapp/src/main/java/webapp/SimpleApplication.java
----------------------------------------------------------------------
diff --git a/example/application/simpleapp/webapp/src/main/java/webapp/SimpleApplication.java b/example/application/simpleapp/webapp/src/main/java/webapp/SimpleApplication.java
index e8b3310..fa557ea 100644
--- a/example/application/simpleapp/webapp/src/main/java/webapp/SimpleApplication.java
+++ b/example/application/simpleapp/webapp/src/main/java/webapp/SimpleApplication.java
@@ -18,6 +18,11 @@
*/
package webapp;
+import de.agilecoders.wicket.core.Bootstrap;
+import de.agilecoders.wicket.core.settings.IBootstrapSettings;
+import de.agilecoders.wicket.themes.markup.html.bootswatch.BootswatchTheme;
+import de.agilecoders.wicket.themes.markup.html.bootswatch.BootswatchThemeProvider;
+
import java.io.IOException;
import java.io.InputStream;
import java.nio.charset.Charset;
@@ -70,7 +75,16 @@ public class SimpleApplication extends IsisWicketApplication {
* for demos only, obvious.
*/
private final static boolean DEMO_MODE_USING_CREDENTIALS_AS_QUERYARGS = false;
-
+
+
+ @Override
+ protected void init() {
+ super.init();
+
+ IBootstrapSettings settings = Bootstrap.getSettings();
+ settings.setThemeProvider(new BootswatchThemeProvider(BootswatchTheme.Flatly));
+ }
+
@Override
public Session newSession(final Request request, final Response response) {
if(!DEMO_MODE_USING_CREDENTIALS_AS_QUERYARGS) {
http://git-wip-us.apache.org/repos/asf/isis/blob/982e1630/example/application/simpleapp/webapp/src/main/webapp/WEB-INF/viewer_wicket.properties
----------------------------------------------------------------------
diff --git a/example/application/simpleapp/webapp/src/main/webapp/WEB-INF/viewer_wicket.properties b/example/application/simpleapp/webapp/src/main/webapp/WEB-INF/viewer_wicket.properties
index 34f1ed0..06d675e 100644
--- a/example/application/simpleapp/webapp/src/main/webapp/WEB-INF/viewer_wicket.properties
+++ b/example/application/simpleapp/webapp/src/main/webapp/WEB-INF/viewer_wicket.properties
@@ -81,4 +81,4 @@ isis.viewer.wicket.themes.showChooser=true
#
# comma-separated list of themes to choose from (default is to show all themes from bootswatch.com).
#
-#isis.viewer.wicket.themes.enabled=bootstrap-theme,Amelia,Flatly,Darkly,Sandstone
+#isis.viewer.wicket.themes.enabled=bootstrap-theme,Cosmo,Flatly,Darkly,Sandstone,United
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/isis/blob/982e1630/example/application/todoapp/webapp/src/main/java/webapp/ToDoApplication.java
----------------------------------------------------------------------
diff --git a/example/application/todoapp/webapp/src/main/java/webapp/ToDoApplication.java b/example/application/todoapp/webapp/src/main/java/webapp/ToDoApplication.java
index 12c17f8..3fa5ba3 100644
--- a/example/application/todoapp/webapp/src/main/java/webapp/ToDoApplication.java
+++ b/example/application/todoapp/webapp/src/main/java/webapp/ToDoApplication.java
@@ -18,6 +18,11 @@
*/
package webapp;
+import de.agilecoders.wicket.core.Bootstrap;
+import de.agilecoders.wicket.core.settings.IBootstrapSettings;
+import de.agilecoders.wicket.themes.markup.html.bootswatch.BootswatchTheme;
+import de.agilecoders.wicket.themes.markup.html.bootswatch.BootswatchThemeProvider;
+
import java.io.IOException;
import java.io.InputStream;
import java.nio.charset.Charset;
@@ -68,7 +73,15 @@ public class ToDoApplication extends IsisWicketApplication {
* for demos only, obvious.
*/
private final static boolean DEMO_MODE_USING_CREDENTIALS_AS_QUERYARGS = false;
-
+
+ @Override
+ protected void init() {
+ super.init();
+
+ IBootstrapSettings settings = Bootstrap.getSettings();
+ settings.setThemeProvider(new BootswatchThemeProvider(BootswatchTheme.Flatly));
+ }
+
@Override
public Session newSession(final Request request, final Response response) {
if(!DEMO_MODE_USING_CREDENTIALS_AS_QUERYARGS) {
http://git-wip-us.apache.org/repos/asf/isis/blob/982e1630/example/application/todoapp/webapp/src/main/webapp/WEB-INF/viewer_wicket.properties
----------------------------------------------------------------------
diff --git a/example/application/todoapp/webapp/src/main/webapp/WEB-INF/viewer_wicket.properties b/example/application/todoapp/webapp/src/main/webapp/WEB-INF/viewer_wicket.properties
index 9731b61..fcdf306 100644
--- a/example/application/todoapp/webapp/src/main/webapp/WEB-INF/viewer_wicket.properties
+++ b/example/application/todoapp/webapp/src/main/webapp/WEB-INF/viewer_wicket.properties
@@ -82,4 +82,5 @@ isis.viewer.wicket.themes.showChooser=true
#
# comma-separated list of themes to choose from (default is to show all themes from bootswatch.com).
#
-#isis.viewer.wicket.themes.enabled=bootstrap-theme,Amelia,Flatly,Darkly,Sandstone
+#isis.viewer.wicket.themes.enabled=bootstrap-theme,Cosmo,Flatly,Darkly,Sandstone,United
+isis.viewer.wicket.themes.enabled=bootstrap-theme,Cosmo,Flatly,Darkly,Sandstone,United