Search in sources :

Example 1 with WorkingSetGroup

use of org.eclipse.ui.dialogs.WorkingSetGroup in project egit by eclipse.

the class GitProjectsImportPage method createWorkingSetGroup.

private void createWorkingSetGroup(Composite workArea) {
    // TODO: replace hardcoded ids once bug 245106 is fixed
    String[] workingSetTypes = new String[] { // $NON-NLS-1$
    "org.eclipse.ui.resourceWorkingSetPage", // $NON-NLS-1$
    "org.eclipse.jdt.ui.JavaWorkingSetPage" };
    workingSetGroup = new WorkingSetGroup(workArea, null, workingSetTypes);
}
Also used : WorkingSetGroup(org.eclipse.ui.dialogs.WorkingSetGroup)

Example 2 with WorkingSetGroup

use of org.eclipse.ui.dialogs.WorkingSetGroup in project webtools.sourceediting by eclipse.

the class DataModelFacetCreationWizardPage method createWorkingSetGroupPanel.

protected WorkingSetGroup createWorkingSetGroupPanel(Composite composite, String[] workingSetTypes) {
    IStructuredSelection structuredSelection = null;
    ISelection currentSelection = PlatformUI.getWorkbench().getActiveWorkbenchWindow().getSelectionService().getSelection();
    if (currentSelection instanceof IStructuredSelection) {
        structuredSelection = (IStructuredSelection) currentSelection;
    }
    WorkingSetGroup group = createWorkingSetGroup(composite, structuredSelection, workingSetTypes);
    return group;
}
Also used : ISelection(org.eclipse.jface.viewers.ISelection) IStructuredSelection(org.eclipse.jface.viewers.IStructuredSelection) WorkingSetGroup(org.eclipse.ui.dialogs.WorkingSetGroup)

Example 3 with WorkingSetGroup

use of org.eclipse.ui.dialogs.WorkingSetGroup in project egit by eclipse.

the class CloneDestinationPage method createProjectGroup.

private void createProjectGroup(final Composite parent) {
    final Group group = createGroup(parent, UIText.CloneDestinationPage_groupProjects);
    GridLayoutFactory.swtDefaults().applyTo(group);
    importProjectsButton = new Button(group, SWT.CHECK);
    importProjectsButton.setText(UIText.CloneDestinationPage_importButton);
    importProjectsButton.setSelection(Activator.getDefault().getPreferenceStore().getBoolean(UIPreferences.CLONE_WIZARD_IMPORT_PROJECTS));
    importProjectsButton.addSelectionListener(new SelectionAdapter() {

        @Override
        public void widgetSelected(SelectionEvent e) {
            Activator.getDefault().getPreferenceStore().setValue(UIPreferences.CLONE_WIZARD_IMPORT_PROJECTS, importProjectsButton.getSelection());
        }
    });
    // TODO: replace hardcoded ids once bug 245106 is fixed
    String[] workingSetTypes = new String[] { // $NON-NLS-1$
    "org.eclipse.ui.resourceWorkingSetPage", // $NON-NLS-1$
    "org.eclipse.jdt.ui.JavaWorkingSetPage" };
    workingSetGroup = new WorkingSetGroup(group, null, workingSetTypes);
}
Also used : WorkingSetGroup(org.eclipse.ui.dialogs.WorkingSetGroup) Group(org.eclipse.swt.widgets.Group) Button(org.eclipse.swt.widgets.Button) SelectionAdapter(org.eclipse.swt.events.SelectionAdapter) SelectionEvent(org.eclipse.swt.events.SelectionEvent) WorkingSetGroup(org.eclipse.ui.dialogs.WorkingSetGroup)

Aggregations

WorkingSetGroup (org.eclipse.ui.dialogs.WorkingSetGroup)3 ISelection (org.eclipse.jface.viewers.ISelection)1 IStructuredSelection (org.eclipse.jface.viewers.IStructuredSelection)1 SelectionAdapter (org.eclipse.swt.events.SelectionAdapter)1 SelectionEvent (org.eclipse.swt.events.SelectionEvent)1 Button (org.eclipse.swt.widgets.Button)1 Group (org.eclipse.swt.widgets.Group)1