Download
Getting Started
Members
Projects
Community
Marketplace
Events
Planet Eclipse
Newsletter
Videos
Participate
Report a Bug
Forums
Mailing Lists
Wiki
IRC
How to Contribute
Working Groups
Automotive
Internet of Things
LocationTech
Long-Term Support
PolarSys
Science
OpenMDM
More
Community
Marketplace
Events
Planet Eclipse
Newsletter
Videos
Participate
Report a Bug
Forums
Mailing Lists
Wiki
IRC
How to Contribute
Working Groups
Automotive
Internet of Things
LocationTech
Long-Term Support
PolarSys
Science
OpenMDM
Toggle navigation
Bugzilla – Attachment 246239 Details for
Bug 361413
[patch] "Select All" is missing from "Edit Software site" dialog in target definition
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
Log In
[x]
|
Terms of Use
|
Copyright Agent
Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read
this important communication.
[patch]
Added Select All and DeSelect All buttons in "Edit Software Site" dialog in target definition
eclipse.pde.ui.patch (text/plain), 3.72 KB, created by
pragya gaur
on 2014-08-22 04:45:25 EDT
(
hide
)
Description:
Added Select All and DeSelect All buttons in "Edit Software Site" dialog in target definition
Filename:
MIME Type:
Creator:
pragya gaur
Created:
2014-08-22 04:45:25 EDT
Size:
3.72 KB
patch
obsolete
>### Eclipse Workspace Patch 1.0 >#P org.eclipse.pde.ui >diff --git src/org/eclipse/pde/internal/ui/shared/target/EditIUContainerPage.java src/org/eclipse/pde/internal/ui/shared/target/EditIUContainerPage.java >index 57231be..6a818b4 100644 >--- src/org/eclipse/pde/internal/ui/shared/target/EditIUContainerPage.java >+++ src/org/eclipse/pde/internal/ui/shared/target/EditIUContainerPage.java >@@ -15,6 +15,7 @@ > import java.net.URISyntaxException; > import org.eclipse.core.runtime.*; > import org.eclipse.equinox.internal.p2.ui.ProvUI; >+import org.eclipse.equinox.internal.p2.ui.ProvUIMessages; > import org.eclipse.equinox.internal.p2.ui.actions.PropertyDialogAction; > import org.eclipse.equinox.internal.p2.ui.dialogs.*; > import org.eclipse.equinox.internal.p2.ui.query.IUViewQueryContext; >@@ -47,6 +48,7 @@ > * @see EditBundleContainerWizard > * @see AddBundleContainerWizard > */ >+@SuppressWarnings("restriction") > public class EditIUContainerPage extends WizardPage implements IEditBundleContainerPage { > > // Status for any errors on the page >@@ -234,9 +236,69 @@ > GridData data = (GridData) fAvailableIUGroup.getStructuredViewer().getControl().getLayoutData(); > data.heightHint = 200; > >- fSelectionCount = SWTFactory.createLabel(parent, NLS.bind(Messages.EditIUContainerPage_itemsSelected, Integer.toString(0)), 1); >+ Composite buttonParent = new Composite(parent, SWT.NONE); >+ GridLayout gridLayout = new GridLayout(); >+ gridLayout.numColumns = 3; >+ gridLayout.marginWidth = 0; >+ gridLayout.horizontalSpacing = 10; >+ buttonParent.setLayout(gridLayout); >+ >+ GridData gridData = new GridData(SWT.FILL, SWT.DEFAULT, true, false); >+ buttonParent.setLayoutData(gridData); >+ >+ Button selectAll = new Button(buttonParent, SWT.PUSH); >+ selectAll.setText(ProvUIMessages.SelectableIUsPage_Select_All); >+ GridData selectAllData = setButtonLayoutData(selectAll); >+ selectAllData.widthHint = 90; >+ >+ selectAll.addListener(SWT.Selection, new Listener() { >+ @Override >+ public void handleEvent(Event event) { >+ setAllChecked(true); >+ } >+ }); >+ >+ Button deselectAll = new Button(buttonParent, SWT.PUSH); >+ deselectAll.setText(ProvUIMessages.SelectableIUsPage_Deselect_All); >+ GridData deselectAllData = setButtonLayoutData(deselectAll); >+ deselectAllData.widthHint = 90; >+ deselectAll.addListener(SWT.Selection, new Listener() { >+ @Override >+ public void handleEvent(Event event) { >+ setAllChecked(false); >+ } >+ }); >+ fSelectionCount = SWTFactory.createLabel(buttonParent, NLS.bind(Messages.EditIUContainerPage_itemsSelected, Integer.toString(0)), 1); >+ GridData labelData = new GridData(); >+ labelData.widthHint = 100; >+ fSelectionCount.setLayoutData(labelData); > } > >+ @SuppressWarnings("deprecation") >+ void setAllChecked(boolean checked) { >+ if (checked) { >+ // TODO ideally there should be API on AvailableIUGroup to do this. >+ // This is reachy and too knowledgeable of the group's implementation. >+ fAvailableIUGroup.getCheckboxTreeViewer().setAllChecked(checked); >+ // to ensure that the listeners get processed. >+ fAvailableIUGroup.setChecked(fAvailableIUGroup.getCheckboxTreeViewer().getCheckedElements()); >+ >+ } else { >+ fAvailableIUGroup.setChecked(new Object[0]); >+ } >+ updateSelection(); >+ } >+ >+ void updateSelection() { >+ int count = fAvailableIUGroup.getCheckedLeafIUs().length; >+ setPageComplete(count > 0); >+ if (count == 0) { >+ fSelectionCount.setText(""); //$NON-NLS-1$ >+ } else { >+ String message = count == 1 ? ProvUIMessages.AvailableIUsPage_SingleSelectionCount : ProvUIMessages.AvailableIUsPage_MultipleSelectionCount; >+ fSelectionCount.setText(NLS.bind(message, Integer.toString(count))); >+ } >+ } > /** > * Details area underneath the group that displays more info on the selected IU > * @param parent parent composite
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 361413
: 246239 |
250533
|
250620
|
251554