&& "rptdesign".equals( ( (IResource) element ).getFileExtension( ) );
&& ReportPlugin.getDefault( ) .getReportExtensionNameList( ) .contains( ( (IResource) element ).getFileExtension( ) );
			public void widgetSelected( SelectionEvent e )			{				if ( chkBoxBrowseFrom.getSelection( ) )				{					FileDialog dialog = new FileDialog( getShell( ) );					dialog.setFilterPath( ResourcesPlugin.getWorkspace( )							.getRoot( )							.getLocation( )							.toOSString( ) );					dialog.setFilterExtensions( new String[]{						"*.rptdesign"} ); //$NON-NLS-1$					if ( dialog.open( ) != null )					{						inputText.setText( dialog.getFilterPath( )								+ File.separator								+ dialog.getFileName( ) );					}				}				else				{					ElementTreeSelectionDialog dialog = new ElementTreeSelectionDialog( getShell( ),							new WorkbenchLabelProvider( ),							new WorkbenchContentProvider( ) );					dialog.setAllowMultiple( false );					dialog.setTitle( MESSAGE_FROM_PROJECT_TITLE );					dialog.setMessage( MESSAGE_FROM_PROJECT_DESCRIPTION );					dialog.setValidator( new ISelectionStatusValidator( ) {						public IStatus validate( Object[] selection )						{							if ( selection == null									|| selection.length < 1									|| selection[0] instanceof IProject									|| selection[0] instanceof IFolder )							{								return new Status( IStatus.ERROR,										ReportPlugin.REPORT_UI,										IStatus.ERROR,										"", null ); //$NON-NLS-1$							}							return new Status( IStatus.OK,									ReportPlugin.REPORT_UI,									IStatus.OK,									"", null ); //$NON-NLS-1$						}					} );					dialog.addFilter( new ViewerFilter( ) {						public boolean select( Viewer viewer,								Object parentElement, Object element )						{							if ( element instanceof IProject									|| element instanceof IFolder )							{								return ( (IResource) element ).isAccessible( );							}							if ( element instanceof IFile )							{								return ( (IResource) element ).isAccessible( )										&& "rptdesign".equals( ( (IResource) element ).getFileExtension( ) ); //$NON-NLS-1$							}							return false;						}					} );					dialog.setInput( ResourcesPlugin.getWorkspace( ).getRoot( ) );					dialog.setSorter( new ResourceSorter( ResourceSorter.NAME ) );					if ( dialog.open( ) == Window.OK )					{						IResource res = (IResource) dialog.getFirstResult( );						inputText.setText( res.getLocation( ).toOSString( ) );					}				}			}