diff --git a/src/com/silverwrist/venice/servlets/format/menus/LeftMenu.java b/src/com/silverwrist/venice/servlets/format/menus/LeftMenu.java
index 3b8953b..00cc15c 100644
--- a/src/com/silverwrist/venice/servlets/format/menus/LeftMenu.java
+++ b/src/com/silverwrist/venice/servlets/format/menus/LeftMenu.java
@@ -62,12 +62,24 @@ public class LeftMenu implements ComponentRender
static class Separator implements ComponentRender
{
+ private ComponentRender cr;
+
Separator()
- { // do nothing
+ {
+ this.cr = null;
+
+ } // end constructor
+
+ Separator(ComponentRender cr)
+ {
+ this.cr = cr;
+
} // end constructor
public void renderHere(Writer out, RenderData rdat) throws IOException
{
+ if (cr!=null)
+ cr.renderHere(out,rdat);
out.write("
\n");
} // end renderHere
@@ -80,7 +92,7 @@ public class LeftMenu implements ComponentRender
*/
private static Category logger = Category.getInstance(LeftMenu.class);
- private static final Separator separator_singleton = new Separator();
+ private static final Separator separator_singleton = new Separator(null);
/*--------------------------------------------------------------------------------
* Attributes
@@ -117,13 +129,13 @@ public class LeftMenu implements ComponentRender
else if (n.getNodeName().equals("text"))
{ // add a text item
DOMElementHelper h = new DOMElementHelper((Element)n);
- menu_items.add(new TextItem(h.getElementText()));
+ menu_items.add(new Separator(new TextItem(h.getElementText())));
} // end else if
else if (n.getNodeName().equals("link"))
menu_items.add(new LinkItem((Element)n));
else if (n.getNodeName().equals("image"))
- menu_items.add(new ImageItem((Element)n));
+ menu_items.add(new Separator(new ImageItem((Element)n)));
else
{ // menu definition has an unknown item
logger.fatal("unknown element <" + n.getNodeName() + "/> inside ");