From dab9ab187078ee1016f35163381d025de99503ad Mon Sep 17 00:00:00 2001 From: Svjatoslav Agejenko Date: Sun, 21 Apr 2013 18:14:45 +0300 Subject: [PATCH] possibility to set default navigation item --- .../commons/network/navigation/Navigation.java | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/src/main/java/eu/svjatoslav/commons/network/navigation/Navigation.java b/src/main/java/eu/svjatoslav/commons/network/navigation/Navigation.java index 7a1f711..1731043 100755 --- a/src/main/java/eu/svjatoslav/commons/network/navigation/Navigation.java +++ b/src/main/java/eu/svjatoslav/commons/network/navigation/Navigation.java @@ -9,6 +9,10 @@ public class Navigation { private NavigationItem defaultNavigationItem; + public NavigationItem getDefaultNavigationItem() { + return defaultNavigationItem; + } + public NavigationItem getRootNavigationItem() { return rootNavigationItem; } @@ -26,7 +30,7 @@ public class Navigation { e.printStackTrace(); } - return defaultNavigationItem; + return getDefaultNavigationItem(); } public String getTopMenu(final String requestUrl) { @@ -53,6 +57,11 @@ public class Navigation { return result.toString(); } + public void setDefaultNavigationItem( + final NavigationItem defaultNavigationItem) { + this.defaultNavigationItem = defaultNavigationItem; + } + public void setRootNavigationItem(final NavigationItem rootNavigationItem) { this.rootNavigationItem = rootNavigationItem; } -- 2.20.1