Index: src/org/eclipse/ui/internal/ide/dialogs/CleanDialog.java =================================================================== RCS file: /cvsroot/eclipse/org.eclipse.ui.ide/src/org/eclipse/ui/internal/ide/dialogs/CleanDialog.java,v retrieving revision 1.24 diff -u -r1.24 CleanDialog.java --- src/org/eclipse/ui/internal/ide/dialogs/CleanDialog.java 2 Jul 2007 22:56:08 -0000 1.24 +++ src/org/eclipse/ui/internal/ide/dialogs/CleanDialog.java 31 Aug 2007 02:07:44 -0000 @@ -1,12 +1,13 @@ /******************************************************************************* - * Copyright (c) 2004, 2006 IBM Corporation and others. + * Copyright (c) 2004, 2007 IBM Corporation and others. * All rights reserved. This program and the accompanying materials * are made available under the terms of the Eclipse Public License v1.0 * which accompanies this distribution, and is available at * http://www.eclipse.org/legal/epl-v10.html * * Contributors: - * IBM - Initial API and implementation + * IBM Corporation - initial API and implementation + * Remy Chi Jian Suen - bug110624 *******************************************************************************/ package org.eclipse.ui.internal.ide.dialogs; @@ -182,7 +183,14 @@ buildNowButton.setLayoutData(new GridData( GridData.HORIZONTAL_ALIGN_BEGINNING)); } - projectNames.getTable().setEnabled(selectSelectedButton); + + if (selectSelectedButton) { + projectNames.getTable().setEnabled(true); + } else { + projectNames.getTable().setEnabled(false); + projectNames.setAllChecked(true); + } + return area; } @@ -253,8 +261,13 @@ * on the current choices in the dialog. */ protected void updateEnablement() { - projectNames.getTable().setEnabled(selectedButton.getSelection()); - boolean enabled = allButton.getSelection() || selection.length > 0; + boolean cleanAll = allButton.getSelection(); + if (cleanAll) { + projectNames.setAllChecked(true); + } + + projectNames.getTable().setEnabled(selectedButton.getSelection()); + boolean enabled = cleanAll || selection.length > 0; getButton(OK).setEnabled(enabled); }