if ( fNumWorkspaceChecked == 0 ) fPluginTreeViewer.setChecked( fWorkspacePlugins, false ); fPluginTreeViewer.setGrayed( fWorkspacePlugins, fNumWorkspaceChecked > 0 && fNumWorkspaceChecked < fWorkspaceModels.length );
for ( int i = 0; i < fWorkspaceJavaModels.length; i++ ) { if ( !deselected.contains( fWorkspaceJavaModels[i].getName( ) ) ) { if ( fPluginTreeViewer.setChecked( fWorkspaceJavaModels[i], false ) ) { fNumWorkspaceJavaChecked--; } } }  fNumWorkspaceChecked = fNumWorkspaceBIRTChecked + fNumWorkspaceJavaChecked; int[] checked = new int[]{ fNumWorkspaceBIRTChecked, fNumWorkspaceJavaChecked }; int[] length = new int[]{ fWorkspaceBIRTModels.length, fWorkspaceJavaModels.length }; for ( int i = 0; i < fWorkspacePlugins.length; i++ ) { if ( checked[i] == 0 ) { fPluginTreeViewer.setChecked( fWorkspacePlugins[i], false ); } fPluginTreeViewer.setGrayed( fWorkspacePlugins[i], checked[i] > 0 && checked[i] < length[i] ); }
	private void initWorkspacePluginsState( ILaunchConfiguration config )			throws CoreException	{		fNumWorkspaceChecked = fWorkspaceModels.length;		fPluginTreeViewer.setSubtreeChecked( fWorkspacePlugins, true );		TreeSet deselected = ReportLauncherUtils.parseDeselectedWSIds( config );		for ( int i = 0; i < fWorkspaceModels.length; i++ )		{			if (!deselected.contains( fWorkspaceModels[i].getName( ) ) )			{				if (fPluginTreeViewer.setChecked( fWorkspaceModels[i], false ))				{					fNumWorkspaceChecked--;				}			}		}		if ( fNumWorkspaceChecked == 0 )			fPluginTreeViewer.setChecked( fWorkspacePlugins, false );		fPluginTreeViewer.setGrayed( fWorkspacePlugins,				fNumWorkspaceChecked > 0						&& fNumWorkspaceChecked < fWorkspaceModels.length );	}