diff --git a/src/com/silverwrist/venice/servlets/format/MenuSIG.java b/src/com/silverwrist/venice/servlets/format/MenuSIG.java index 1ca77ba..a4f9a52 100644 --- a/src/com/silverwrist/venice/servlets/format/MenuSIG.java +++ b/src/com/silverwrist/venice/servlets/format/MenuSIG.java @@ -25,12 +25,22 @@ import com.silverwrist.venice.core.*; public class MenuSIG implements ComponentRender, ColorSelectors { - private String image_url; - private boolean image_url_needs_fixup = false; - private String title; - private List items_list; - private int sigid; - private boolean show_unjoin; + /*-------------------------------------------------------------------------------- + * Attributes + *-------------------------------------------------------------------------------- + */ + + private String image_url; // path to actual image + private boolean image_url_needs_fixup = false; // do we need to fix image path up? + private String title; // title for menu + private List items_list; // list of menu items + private int sigid; // SIG ID + private boolean show_unjoin; // show the "Unjoin" menu choice? + + /*-------------------------------------------------------------------------------- + * Constructor + *-------------------------------------------------------------------------------- + */ public MenuSIG(SIGContext ctxt) { @@ -59,15 +69,14 @@ public class MenuSIG implements ComponentRender, ColorSelectors } // end constructor - public int getID() - { - return sigid; - - } // end getID + /*-------------------------------------------------------------------------------- + * Implementations from interface ComponentRender + *-------------------------------------------------------------------------------- + */ public void renderHere(Writer out, RenderData rdat) throws IOException { - String hilite = ""; + String hilite = rdat.getStdFontTag(LEFT_LINK,2); if (image_url!=null) { // display the image by URL if (image_url_needs_fixup) @@ -86,21 +95,34 @@ public class MenuSIG implements ComponentRender, ColorSelectors // display the menu items Iterator it = items_list.iterator(); + String sigparm = "sig=" + sigid; while (it.hasNext()) { // display each menu item in turn SIGFeature ftr = (SIGFeature)(it.next()); - out.write("
\n" + hilite + StringUtil.encodeHTML(ftr.getName()) + "
\n"); + out.write("
\n" + hilite + + StringUtil.encodeHTML(ftr.getName()) + "\n"); } // end while if (show_unjoin) - out.write("

\n" + hilite + "Unjoin\n"); + out.write("

\n" + + hilite + "Unjoin\n"); out.write("\n"); // all done... } // end renderHere + /*-------------------------------------------------------------------------------- + * External operations + *-------------------------------------------------------------------------------- + */ + + public int getID() + { + return sigid; + + } // end getID + } // end class MenuTop