コード例 #1
0
ファイル: InterfaceModel.java プロジェクト: coi123/coi
 // returns the current value pair contained in the panelgroup
 public String getCurrentPanelChildValue(int childIndex) {
   Object obj = currentPanel.getChildren().get(childIndex);
   String returnStr = "";
   if (obj instanceof HtmlSelectOneMenu) {
     HtmlSelectOneMenu menu = (HtmlSelectOneMenu) obj;
     returnStr = menu.getValue().toString();
   } else if (obj instanceof HtmlInputText) {
     HtmlInputText text = (HtmlInputText) obj;
     returnStr = text.getValue().toString();
   } else if (obj instanceof HtmlOutputText) {
     HtmlOutputText text = (HtmlOutputText) obj;
     returnStr = text.getValue().toString();
   }
   return returnStr;
 }
コード例 #2
0
ファイル: InterfaceModel.java プロジェクト: coi123/coi
 private HtmlOutputText buildOutputTextField(String value, CustomButtonNode parent) {
   HtmlOutputText text = new HtmlOutputText();
   text.setValue(value);
   text.setStyle("margin-left:" + (parent.getOffset() + 5) + "px;");
   return text;
 }