Bug 316674 Refactor data set editor pages' codes[26569]
Build Identifier: 20100610 Refactor data set editor pages' codes[26569]. Reproducible: Always
UI/org.eclipse.birt.report.designer.ui.data/src/org/eclipse/birt/report/designer/data/ui/dataset/DataSetEditor.java
.booleanValue( );
				
				IConfigurationElement[] editorPages = element.getChildren( "dataSetEditorPage" );
				if ( editorPages != null )
				{
					boolean hasFocus = false;
					for ( int n = 0; n < editorPages.length; n++ )
					{
						IPropertyPage page = (IPropertyPage) editorPages[n].createExecutableExtension( "class" );
						addPageTo( editorPages[n].getAttribute( "path" ), editorPages[n].getAttribute( "name" ), editorPages[n].getAttribute( "displayName" ), null, page );
						if ( hasFocus == false )
						{
							String initFocusAttr = editorPages[n].getAttribute( "initFocus" ); 
							if ( initFocusAttr != null
									&& initFocusAttr.equalsIgnoreCase( "true" ) ) 
							{
								setDefaultNode( editorPages[n].getAttribute( "name" ) ); 
								hasFocus = true;
							}
							else if ( n == editorPages.length - 1 )
							{
								setDefaultNode( editorPages[0].getAttribute( "name" ) ); 
							}
						}
					}
				}
			}
		}
		catch ( CoreException e1 )
		{