|
|
Re: Visible or Invisible Properties When model changed [message #1114453 is a reply to message #1113456] |
Sun, 22 September 2013 19:24 |
serhat gezgin Messages: 243 Registered: January 2013 Location: Izmir |
Senior Member |
|
|
Thanks a lot i solve this like;
@Override
public List<IItemPropertyDescriptor> getPropertyDescriptors(Object object) {
itemPropertyDescriptors = null;
super.getPropertyDescriptors(object);
addTypePropertyDescriptor(object);
addNullablePropertyDescriptor(object);
addDefaultValuePropertyDescriptor(object);
addPrimaryKeyPropertyDescriptor(object);
if (ColumnUtil.isAutoIncrementSettable(((Column) object)))
addAutoIncrementPropertyDescriptor(object);
return itemPropertyDescriptors;
}
and when model changed;
public void notifyChanged(Notification notification) {
updateChildren(notification);
switch (notification.getFeatureID(Column.class)) {
case ContentPackage.COLUMN__TYPE:
getPropertyDescriptors(notification.getNotifier());
case ContentPackage.COLUMN__NULLABLE:
case ContentPackage.COLUMN__DEFAULT_VALUE:
case ContentPackage.COLUMN__PRIMARY_KEY:
case ContentPackage.COLUMN__AUTO_INCREMENT:
fireNotifyChanged(new ViewerNotification(notification,
notification.getNotifier(), false, true));
return;
}
super.notifyChanged(notification);
}
Regards
[Updated on: Sun, 22 September 2013 19:40] Report message to a moderator
|
|
|
Powered by
FUDForum. Page generated in 0.01792 seconds