--- TGWikiBrowser.java Tue Jun 11 12:28:44 2002 +++ TGWikiBrowser.java Thu Jul 8 22:22:01 2004 @@ -92,11 +92,11 @@ public JPopupMenu wikiPopup; - private JTextField tfSearch; - private JComboBox maxAddCombo; - private JComboBox maxExpandCombo; - private JComboBox localityRadiusCombo; - private JCheckBox showBackLinksCheckBox; + protected JTextField tfSearch; + protected JComboBox maxAddCombo; + protected JComboBox maxExpandCombo; + protected JComboBox localityRadiusCombo; + protected JCheckBox showBackLinksCheckBox; public JTextPane tpWikiText; public String textPaneURL = null; @@ -114,7 +114,11 @@ public static boolean INITIAL_SHOW_BACKLINKS=false; public TGWikiBrowser() { - + init(); + } + + /* TODO: catch UnknownHostException */ + protected void init() { completeEltSet = new GraphEltSet(); tgPanel = new TGPanel(); tgPanel.setGraphEltSet(completeEltSet); @@ -165,7 +169,7 @@ } private String generateNodeLabel(String labelOrUrl) { - if(!labelOrUrl.startsWith("http://")) { + if((!labelOrUrl.startsWith("http://")) || (!labelOrUrl.startsWith("https://"))) { return labelOrUrl; //It's a label } else { // Create a label from the URL @@ -193,7 +197,7 @@ n = new WikiNode(generateNodeLabel(str)); - if (!str.startsWith("http://")) { + if ((!str.startsWith("http://")) || (!str.startsWith("https://"))) { n.setURL(WIKI_URL + str); } else { @@ -216,7 +220,7 @@ { BufferedReader bdbReader; - if(WIKI_FILE.startsWith("http://")) { + if((WIKI_FILE.startsWith("http://")) || (WIKI_FILE.startsWith("https://"))) { URLConnection wfConn = (new URL(WIKI_FILE)).openConnection(); SFSInputStream sfsInputStream = new SFSInputStream(wfConn.getInputStream(), wfConn.getContentLength()); @@ -351,7 +355,8 @@ tgLensSet.addLens(tgPanel.getAdjustOriginLens()); } - private void buildPanel() { + // lowered access restrictions so TGWikiPanel can call this */ + protected void buildPanel() { final JScrollBar horizontalSB = hvScroll.getHorizontalSB(); final JScrollBar verticalSB = hvScroll.getVerticalSB(); final JScrollBar zoomSB = zoomScroll.getZoomSB(); @@ -592,7 +597,8 @@ setWikiTextPane(n.getURL()); } - private class BackButton extends JButton { + /* lowered access rights so TGWikiPanel can overload this */ + protected class BackButton extends JButton { BackButton() { super("< Back"); setPreferredSize(new Dimension(80,20));