Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
View | Details | Raw Unified | Return to bug 233183 | Differences between
and this patch

Collapse All | Expand All

(-)src/org/eclipse/equinox/internal/provisional/p2/ui/actions/InstallAction.java (-1 / +11 lines)
Lines 99-105 Link Here
99
	 * @see org.eclipse.equinox.internal.provisional.p2.ui.actions.ProfileModificationAction#isEnabledFor(java.lang.Object[])
99
	 * @see org.eclipse.equinox.internal.provisional.p2.ui.actions.ProfileModificationAction#isEnabledFor(java.lang.Object[])
100
	 */
100
	 */
101
	protected boolean isEnabledFor(Object[] selectionArray) {
101
	protected boolean isEnabledFor(Object[] selectionArray) {
102
		return selectionArray.length > 0;
102
		if (selectionArray.length == 0)
103
			return false;
104
		// We allow non-IU's to be selected at this point, but there
105
		// must be at least one installable unit selected that is
106
		// not a category.  
107
		for (int i = 0; i < selectionArray.length; i++) {
108
			IInstallableUnit iu = getIU(selectionArray[i]);
109
			if (iu != null && !ProvisioningUtil.isCategory(iu))
110
				return true;
111
		}
112
		return false;
103
	}
113
	}
104
114
105
	protected String getTaskName() {
115
	protected String getTaskName() {

Return to bug 233183