19 package org.turro.elephant.configuration;
22 import org.turro.elephant.context.ElephantContext;
23 import org.turro.i18n.I_;
24 import org.zkoss.zk.ui.ext.AfterCompose;
25 import org.zkoss.zul.Tree;
26 import org.zkoss.zul.Treechildren;
27 import org.zkoss.zul.Treeitem;
33 public class FilesTree extends Tree implements AfterCompose {
40 return (
FilesItem) getSelectedItem().getParentItem();
52 for(Treeitem ti : parent.getTreechildren().getItems()) {
53 if(file.equals(ti.getValue())) {
62 Treechildren children =
new Treechildren();
63 appendChild(children);
73 I_.
get(
"Properties"),
".*\\.properties"));
76 I_.
get(
"Resources"),
"by-key-site_en\\.properties"));
79 I_.
get(
"Search"),
"dao-search.*\\.xml"));
82 "JSON",
".*\\.json"));
85 "Mail providers",
".*\\.json"));
87 if(scripts.exists()) {
89 "Scripts",
".*\\.js"));
91 children.appendChild(configuration);
93 if(support.exists()) {
94 children.appendChild(
new FilesItem(support,
95 I_.
get(
"Support"),
null));
103 children.appendChild(css);
105 if(tmplMail.exists()) {
106 children.appendChild(
new FilesItem(tmplMail,
107 I_.
get(
"Templates") +
"-mail",
null));
110 if(tmplSemantic.exists()) {
111 children.appendChild(
new FilesItem(tmplSemantic,
112 I_.
get(
"Templates") +
"-semantic",
null));
115 if(tmplSemanticApp.exists()) {
116 children.appendChild(
new FilesItem(tmplSemanticApp,
117 I_.
get(
"Templates") +
"-semantic-app",
null));
120 if(reports.exists()) {
121 children.appendChild(
new FilesItem(reports,
122 I_.
get(
"Reports"),
null));
127 I_.
get(
"Terms of Use"),
null));
138 children.appendChild(wiki);
void addFile(FilesItem file)
FilesItem getSelectedFolder()
void selectFile(File file, Treeitem parent)
FilesItem getSelectedFile()
FilesItem getSelectedFileParent()
static String getRealPath(String path)
static String get(String msg)