Permalink
Browse files

Document.

  • Loading branch information...
Thynix committed Apr 20, 2012
1 parent 8a6f5cc commit 0d0423efba62be878aac49310b2b97b43d7f4b3d
Showing with 20 additions and 2 deletions.
  1. +20 −2 src/freenet/clients/http/LocalFileBrowserToadlet.java
@@ -119,7 +119,13 @@ protected String defaultDownloadDir() {
//If locations are explicitly specified take the first one.
return core.getAllowedDownloadDirs()[0].getAbsolutePath();
}
-
+
+ /**
+ * Renders directory selection button with selectDir and filenameField() set.
+ * @param node Node to add the button to.
+ * @param absolutePath Path to set the filenameField() field to.
+ * @param persistence Additional persistence fields to include.
+ */
protected void createSelectDirectoryButton (HTMLNode node, String absolutePath, HTMLNode persistence) {
node.addChild("input",
new String[]{"type", "name", "value"},
@@ -129,7 +135,13 @@ protected void createSelectDirectoryButton (HTMLNode node, String absolutePath,
new String[]{"hidden", filenameField(), absolutePath});
node.addChild(persistence);
}
-
+
+ /**
+ * Renders file selection button with selectFile and filenameField() set.
+ * @param node Node to add the button to.
+ * @param absolutePath Path to set the filenameField() field to.
+ * @param persistence Additional persistence fields to include.
+ */
protected void createSelectFileButton (HTMLNode node, String absolutePath, HTMLNode persistence) {
node.addChild("input",
new String[]{"type", "name", "value"},
@@ -140,6 +152,12 @@ protected void createSelectFileButton (HTMLNode node, String absolutePath, HTMLN
node.addChild(persistence);
}
+ /**
+ * Renders directory changing button with changeDir and filenameField() set.
+ * @param node Node to add the button to.
+ * @param path Path to set the "path" field to.
+ * @param persistence Additional persistence fields to include.
+ */
private void createChangeDirButton (HTMLNode node, String buttonText, String path, HTMLNode persistence) {
node.addChild("input",
new String[]{"type", "name", "value"},

0 comments on commit 0d0423e

Please sign in to comment.