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 251554 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]
Last patch aligned with master code
patch_aligned_to_master.patch (text/plain), 3.69 KB, created by
Vikas Chandra
on 2015-03-14 10:45:52 EDT
(
hide
)
Description:
Last patch aligned with master code
Filename:
MIME Type:
Creator:
Vikas Chandra
Created:
2015-03-14 10:45:52 EDT
Size:
3.69 KB
patch
obsolete
>diff --git a/ui/org.eclipse.pde.ui/src/org/eclipse/pde/internal/ui/shared/target/EditIUContainerPage.java b/ui/org.eclipse.pde.ui/src/org/eclipse/pde/internal/ui/shared/target/EditIUContainerPage.java >index f57b673..93227a0 100644 >--- a/ui/org.eclipse.pde.ui/src/org/eclipse/pde/internal/ui/shared/target/EditIUContainerPage.java >+++ b/ui/org.eclipse.pde.ui/src/org/eclipse/pde/internal/ui/shared/target/EditIUContainerPage.java >@@ -16,6 +16,7 @@ > import java.util.concurrent.atomic.AtomicBoolean; > 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; >@@ -303,7 +304,75 @@ > GridData data = (GridData) fAvailableIUGroup.getStructuredViewer().getControl().getLayoutData(); > data.heightHint = 200; > >- fSelectionCount = SWTFactory.createLabel(parent, NLS.bind(Messages.EditIUContainerPage_itemsSelected, Integer.toString(0)), 1); >+ // 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 = 200; >+ fSelectionCount.setLayoutData(labelData); >+ } >+ >+ void setAllChecked(boolean checked) { >+ if (checked) { >+ TreeItem[] items = fAvailableIUGroup.getCheckboxTreeViewer().getTree().getItems(); >+ checkAll(checked, items); >+ fAvailableIUGroup.setChecked(fAvailableIUGroup.getCheckboxTreeViewer().getCheckedElements()); >+ } else { >+ fAvailableIUGroup.setChecked(new Object[0]); >+ } >+ updateSelection(); >+ } >+ >+ private void checkAll(boolean checked, TreeItem[] items) { >+ for (int i = 0; i < items.length; i++) { >+ items[i].setChecked(checked); >+ TreeItem[] children = items[i].getItems(); >+ checkAll(checked, children); >+ } >+ } >+ >+ void updateSelection() { >+ int count = fAvailableIUGroup.getCheckedLeafIUs().length; >+ setPageComplete(count > 0); >+ String message; >+ if (count == 0) { >+ message = ProvUIMessages.AvailableIUsPage_MultipleSelectionCount; >+ fSelectionCount.setText(NLS.bind(message, Integer.toString(count))); >+ } else { >+ message = count == 1 ? ProvUIMessages.AvailableIUsPage_SingleSelectionCount : ProvUIMessages.AvailableIUsPage_MultipleSelectionCount; >+ fSelectionCount.setText(NLS.bind(message, Integer.toString(count))); >+ } > } > > /**
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