Esempio n. 1
0
 public void layoutInputText(Composite fields, List<Entry> entries) {
   v.layoutEditor(ATTR_ID, fields);
   v.layoutEditor(ATTR_TYPE, fields);
   LayoutUtil.createSeparator(fields);
   v.layoutEditor(ATTR_NAME, fields);
   v.layoutEditor(ATTR_VALUE, fields);
   LayoutUtil.createSeparator(fields);
   if (!v.context.isRangeType()) {
     v.layoutEditor(JQueryHTMLConstants.ATTR_PLACEHOLDER, fields);
     v.layoutEditor(JQueryHTMLConstants.ATTR_MAXLENGTH, fields);
     v.layoutEditor(JQueryHTMLConstants.ATTR_PATTERN, fields);
     LayoutUtil.createSeparator(fields);
   }
   TwoColumns cs = LayoutUtil.createTwoColumns(fields);
   v.layoutEditor(JQueryHTMLConstants.ATTR_REQUIRED, cs.left());
   v.layoutEditor(ATTR_READONLY, cs.right());
   v.layoutEditor(ATTR_DISABLED, cs.left());
   v.layoutEditor(JQueryHTMLConstants.ATTR_AUTOFOCUS, cs.right());
   if (v.context.isFileType()) {
     v.layoutEditor(ATTR_MULTIPLE, cs.left());
     JQueryFieldEditorFactory.createSpan("file-span", 3).doFillIntoGrid(cs.right());
   }
   if (v.context.isNumberType() || v.context.isRangeType()) {
     Composite[] cs3 = LayoutUtil.createColumns(fields, 3);
     v.layoutEditor(JQueryHTMLConstants.ATTR_DATA_MIN, cs3[0]);
     v.layoutEditor(JQueryHTMLConstants.ATTR_DATA_MAX, cs3[1]);
     v.layoutEditor(JQueryHTMLConstants.ATTR_DATA_STEP, cs3[2]);
   }
   LayoutUtil.createSeparator(fields);
   v.layoutEditor(ATTR_FORM, fields);
 }
Esempio n. 2
0
 public void layoutInputCheckbox(Composite fields, List<Entry> entries) {
   v.layoutEditor(ATTR_ID, fields);
   v.layoutEditor(ATTR_TYPE, fields);
   LayoutUtil.createSeparator(fields);
   v.layoutEditor(ATTR_NAME, fields);
   v.layoutEditor(ATTR_VALUE, fields);
   LayoutUtil.createSeparator(fields);
   TwoColumns cs = LayoutUtil.createTwoColumns(fields);
   v.layoutEditor(CHECKED, cs.left());
   v.layoutEditor(ATTR_DISABLED, cs.right());
   v.layoutEditor(JQueryHTMLConstants.ATTR_AUTOFOCUS, cs.left());
   JQueryFieldEditorFactory.createSpan("checkbox-span", 3).doFillIntoGrid(cs.right());
   LayoutUtil.createSeparator(fields);
   v.layoutEditor(ATTR_FORM, fields);
 }
Esempio n. 3
0
 public void layoutSelect(Composite fields, List<Entry> entries) {
   v.layoutEditor(ATTR_ID, fields);
   v.layoutEditor(ATTR_NAME, fields);
   LayoutUtil.createSeparator(fields);
   TwoColumns cs = LayoutUtil.createTwoColumns(fields);
   v.layoutEditor(ATTR_DISABLED, cs.left());
   v.layoutEditor(JQueryHTMLConstants.ATTR_AUTOFOCUS, cs.right());
   if (v.hasEditor(JQueryHTMLConstants.ATTR_REQUIRED)) {
     v.layoutEditor(JQueryHTMLConstants.ATTR_REQUIRED, cs.left());
   } else {
     JQueryFieldEditorFactory.createSpan("select-span", 3).doFillIntoGrid(cs.left());
   }
   v.layoutEditor(ATTR_MULTIPLE, cs.right());
   LayoutUtil.createSeparator(fields);
   v.layoutEditor(ATTR_SIZE, fields);
   v.layoutEditor(ATTR_FORM, fields);
 }