ts.addTab(mainLayout, "Description", null);
}
+
+ // Properties table tab
+ ts.addTab(getPropertyPanel().getAllProperties(), "Properties", null);
// Javadoc tab
if (!javadoc.getValue().equals(""))
Label.CONTENT_PREFORMATTED));
ts.addTab(l, "Code Sample", null);
}
-
+
layout.addComponent(ts);
}
private Button setButton = new Button("Set", this);
private Button discardButton = new Button("Discard changes", this);
-
- private Button showAllProperties = new Button("List of All Properties",
- this);
-
+
private Table allProperties = new Table();
private Object objectToConfigure;
// Control buttons
OrderedLayout buttons = new OrderedLayout(
- OrderedLayout.ORIENTATION_VERTICAL);
+ OrderedLayout.ORIENTATION_HORIZONTAL);
buttons.addComponent(setButton);
buttons.addComponent(discardButton);
addComponent(buttons);
addComponentContainerProperties();
// The list of all properties
- addComponent(showAllProperties);
- showAllProperties.setSwitchMode(true);
- allProperties.setVisible(false);
allProperties.addContainerProperty("Name", String.class, "");
allProperties.addContainerProperty("Type", String.class, "");
allProperties.addContainerProperty("R/W", String.class, "");
allProperties.setColumnAlignments(new String[] { Table.ALIGN_LEFT,
Table.ALIGN_LEFT, Table.ALIGN_CENTER, Table.ALIGN_CENTER });
allProperties.setColumnHeaderMode(Table.COLUMN_HEADER_MODE_ID);
+ allProperties.setPageLength(0);
updatePropertyList();
- addComponent(allProperties);
}
/** Add a formful of properties to property panel */
((Form) i.next()).discard();
}
- // Show property list
- if (event.getButton() == showAllProperties) {
- allProperties.setVisible(((Boolean) showAllProperties.getValue())
- .booleanValue());
- }
}
/** Recreate property list contents */
}
return null;
}
+
+ public Table getAllProperties() {
+ return allProperties;
+ }
}