org.eclipse.swt.SWTException: Subclassing not allowed
at org.eclipse.swt.SWT.error(SWT.java:4282)
at org.eclipse.swt.SWT.error(SWT.java:4197)
at org.eclipse.swt.SWT.error(SWT.java:4168)
at org.eclipse.swt.widgets.Widget.error(Widget.java:468)
at org.eclipse.swt.widgets.Group.checkSubclass(Group.java:149)
重载SWT的Group类时出现,子类不允许创建的错误。
解决方法:
重载checkSubclass方法。
@Override
protected void checkSubclass() {
// TODO Auto-generated method stub
// super.checkSubclass();
}