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 161680 Details for
Bug 291954
JAX-RS: Implement JAX-RS Facet
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
Log In
[x]
|
Terms of Use
|
Copyright Agent
[patch]
patch
patch.txt (text/plain), 25.03 KB, created by
Eric Peters
on 2010-03-10 16:59:52 EST
(
hide
)
Description:
patch
Filename:
MIME Type:
Creator:
Eric Peters
Created:
2010-03-10 16:59:52 EST
Size:
25.03 KB
patch
obsolete
>### Eclipse Workspace Patch 1.0 >#P org.eclipse.jst.ws.jaxrs.core >Index: src/org/eclipse/jst/ws/jaxrs/core/internal/project/facet/IJAXRSSharedLibraryProviderInstallOperationConfig.java >=================================================================== >RCS file: src/org/eclipse/jst/ws/jaxrs/core/internal/project/facet/IJAXRSSharedLibraryProviderInstallOperationConfig.java >diff -N src/org/eclipse/jst/ws/jaxrs/core/internal/project/facet/IJAXRSSharedLibraryProviderInstallOperationConfig.java >--- /dev/null 1 Jan 1970 00:00:00 -0000 >+++ src/org/eclipse/jst/ws/jaxrs/core/internal/project/facet/IJAXRSSharedLibraryProviderInstallOperationConfig.java 1 Jan 1970 00:00:00 -0000 >@@ -0,0 +1,33 @@ >+/******************************************************************************* >+ * Copyright (c) 2010 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 Corporation - initial API and implementation >+ * yyyymmdd bug Email and other contact information >+ * -------- -------- ----------------------------------------------------------- >+ * 20100310 291954 ericdp@ca.ibm.com - Eric D. Peters, JAX-RS: Implement JAX-RS Facet >+ *******************************************************************************/ >+package org.eclipse.jst.ws.jaxrs.core.internal.project.facet; >+ >+import org.eclipse.wst.common.frameworks.datamodel.IDataModel; >+ >+ >+public interface IJAXRSSharedLibraryProviderInstallOperationConfig { >+ >+ public void setSharedLibrary(boolean isSharedLibrary); >+ >+ public boolean isSharedLibrary(); >+ >+ public void setIsDeploy(boolean isDeploy); >+ >+ public boolean isDeploy(); >+ >+ public void setModel(IDataModel model); >+ >+ public IDataModel getModel(); >+ >+} >Index: src/org/eclipse/jst/ws/jaxrs/core/internal/project/facet/JAXRSSharedLibraryProviderInstallOperationConfig.java >=================================================================== >RCS file: src/org/eclipse/jst/ws/jaxrs/core/internal/project/facet/JAXRSSharedLibraryProviderInstallOperationConfig.java >diff -N src/org/eclipse/jst/ws/jaxrs/core/internal/project/facet/JAXRSSharedLibraryProviderInstallOperationConfig.java >--- /dev/null 1 Jan 1970 00:00:00 -0000 >+++ src/org/eclipse/jst/ws/jaxrs/core/internal/project/facet/JAXRSSharedLibraryProviderInstallOperationConfig.java 1 Jan 1970 00:00:00 -0000 >@@ -0,0 +1,50 @@ >+/******************************************************************************* >+ * Copyright (c) 2010 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 Corporation - initial API and implementation >+ * yyyymmdd bug Email and other contact information >+ * -------- -------- ----------------------------------------------------------- >+ * 20100310 291954 ericdp@ca.ibm.com - Eric D. Peters, JAX-RS: Implement JAX-RS Facet >+ *******************************************************************************/ >+package org.eclipse.jst.ws.jaxrs.core.internal.project.facet; >+ >+import org.eclipse.jst.common.project.facet.core.libprov.user.UserLibraryProviderInstallOperationConfig; >+import org.eclipse.wst.common.frameworks.datamodel.IDataModel; >+ >+public class JAXRSSharedLibraryProviderInstallOperationConfig extends UserLibraryProviderInstallOperationConfig implements IJAXRSSharedLibraryProviderInstallOperationConfig { >+ private boolean isSharedLibrary = true; >+ private boolean isDeploy = false; >+ private IDataModel model = null; >+ >+ public void setSharedLibrary(boolean isSharedLibrary) >+ { >+ this.isSharedLibrary = isSharedLibrary; >+// setIncludeWithApplicationEnabled(!isSharedLibrary); >+ } >+ >+ public boolean isSharedLibrary() >+ { >+ return this.isSharedLibrary; >+ } >+ >+ public void setIsDeploy(boolean isDeploy) { >+ this.isDeploy = isDeploy; >+ } >+ >+ public boolean isDeploy() { >+ return this.isDeploy; >+ } >+ >+ public void setModel(IDataModel model) { >+ this.model = model; >+ } >+ >+ public IDataModel getModel() { >+ return model; >+ } >+} >Index: src/org/eclipse/jst/ws/jaxrs/core/internal/project/facet/JAXRSUserLibraryProviderInstallOperationConfig.java >=================================================================== >RCS file: /cvsroot/webtools/webservices/plugins/org.eclipse.jst.ws.jaxrs.core/src/org/eclipse/jst/ws/jaxrs/core/internal/project/facet/JAXRSUserLibraryProviderInstallOperationConfig.java,v >retrieving revision 1.2 >diff -u -r1.2 JAXRSUserLibraryProviderInstallOperationConfig.java >--- src/org/eclipse/jst/ws/jaxrs/core/internal/project/facet/JAXRSUserLibraryProviderInstallOperationConfig.java 4 Mar 2010 03:49:58 -0000 1.2 >+++ src/org/eclipse/jst/ws/jaxrs/core/internal/project/facet/JAXRSUserLibraryProviderInstallOperationConfig.java 10 Mar 2010 21:49:52 -0000 >@@ -10,6 +10,7 @@ > * yyyymmdd bug Email and other contact information > * -------- -------- ----------------------------------------------------------- > * 20100303 291954 kchong@ca.ibm.com - Keith Chong, JAX-RS: Implement JAX-RS Facet >+ * 20100310 291954 ericdp@ca.ibm.com - Eric D. Peters, JAX-RS: Implement JAX-RS Facet > *******************************************************************************/ > package org.eclipse.jst.ws.jaxrs.core.internal.project.facet; > >@@ -17,7 +18,7 @@ > import org.eclipse.wst.common.frameworks.datamodel.IDataModel; > > public class JAXRSUserLibraryProviderInstallOperationConfig extends >- WtpUserLibraryProviderInstallOperationConfig { >+ WtpUserLibraryProviderInstallOperationConfig implements IJAXRSSharedLibraryProviderInstallOperationConfig { > > public JAXRSUserLibraryProviderInstallOperationConfig() { > // TODO Auto-generated constructor stub >#P org.eclipse.jst.ws.jaxrs.ui >Index: src/org/eclipse/jst/ws/jaxrs/ui/internal/project/facet/JAXRSFacetIncludeLibrariesGroup.java >=================================================================== >RCS file: src/org/eclipse/jst/ws/jaxrs/ui/internal/project/facet/JAXRSFacetIncludeLibrariesGroup.java >diff -N src/org/eclipse/jst/ws/jaxrs/ui/internal/project/facet/JAXRSFacetIncludeLibrariesGroup.java >--- /dev/null 1 Jan 1970 00:00:00 -0000 >+++ src/org/eclipse/jst/ws/jaxrs/ui/internal/project/facet/JAXRSFacetIncludeLibrariesGroup.java 1 Jan 1970 00:00:00 -0000 >@@ -0,0 +1,113 @@ >+/******************************************************************************* >+ * Copyright (c) 2010 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 Corporation - initial API and implementation >+ * yyyymmdd bug Email and other contact information >+ * -------- -------- ----------------------------------------------------------- >+ * 20100310 291954 ericdp@ca.ibm.com - Eric D. Peters, JAX-RS: Implement JAX-RS Facet >+ *******************************************************************************/ >+package org.eclipse.jst.ws.jaxrs.ui.internal.project.facet; >+ >+import org.eclipse.jst.ws.jaxrs.core.internal.project.facet.IJAXRSFacetInstallDataModelProperties; >+import org.eclipse.jst.ws.jaxrs.ui.internal.JAXRSUIPlugin; >+import org.eclipse.jst.ws.jaxrs.ui.internal.Messages; >+import org.eclipse.swt.SWT; >+import org.eclipse.swt.events.SelectionAdapter; >+import org.eclipse.swt.events.SelectionEvent; >+import org.eclipse.swt.layout.GridData; >+import org.eclipse.swt.layout.GridLayout; >+import org.eclipse.swt.widgets.Button; >+import org.eclipse.swt.widgets.Composite; >+import org.eclipse.ui.PlatformUI; >+import org.eclipse.wst.common.frameworks.datamodel.IDataModel; >+ >+public class JAXRSFacetIncludeLibrariesGroup extends Composite { >+ >+ private Button btnDeployJars; >+ private Button btnSharedLibrary; >+ Button copyOnPublishCheckBox; >+ private Composite includeLibRadiosComposite; >+ >+ public JAXRSFacetIncludeLibrariesGroup(Composite parent, int style) { >+ super(parent, style); >+ copyOnPublishCheckBox = new Button(parent, SWT.CHECK); >+ copyOnPublishCheckBox.setText(Messages.JAXRSLibraryConfigControl_IncludeGroupLabel); >+ includeLibRadiosComposite = new Composite(parent, SWT.NONE); >+ GridLayout gridlayout = new GridLayout(); >+ gridlayout.numColumns = 1; >+ gridlayout.marginTop = 0; >+ gridlayout.marginBottom = 0; >+ gridlayout.marginRight = 0; >+ gridlayout.marginLeft = 10; >+ >+ includeLibRadiosComposite.setLayout(gridlayout); >+ GridData griddata = new GridData(GridData.FILL_HORIZONTAL); >+ includeLibRadiosComposite.setLayoutData(griddata); >+ >+ btnDeployJars = createRadioButton(includeLibRadiosComposite, Messages.JAXRSLibraryConfigControl_DeployButtonLabel, Messages.JAXRSLibraryConfigControl_DeployJAR, null); >+ >+ btnSharedLibrary = createRadioButton(includeLibRadiosComposite, Messages.JAXRSLibraryConfigControl_SharedLibButtonLabel, Messages.JAXRSLibraryConfigControl_TooltipIncludeAsSharedLib, null); >+ >+ copyOnPublishCheckBox.addSelectionListener(new SelectionAdapter() >+ { >+ public void widgetSelected(final SelectionEvent event) >+ { >+ boolean selection = copyOnPublishCheckBox.getSelection(); >+ btnDeployJars.setEnabled(selection); >+ btnSharedLibrary.setEnabled(selection); >+ >+ } >+ }); >+ // Need to initialize this properly >+ btnDeployJars.setSelection(true); >+ >+ } >+ >+ public Button getBtnDeployJars() { >+ return btnDeployJars; >+ } >+ >+ public Button getBtnSharedLibrary() { >+ return btnSharedLibrary; >+ } >+ >+ public Button getCopyOnPublishCheckBox() { >+ return copyOnPublishCheckBox; >+ } >+ >+ public Composite getIncludeLibRadiosComposite() { >+ return includeLibRadiosComposite; >+ } >+ >+ private Button createButton(int kind, Composite parent, String labelName, String tooltip, String infopop) >+ { >+ Button button = new Button(parent, kind); >+ >+ tooltip = tooltip == null ? labelName : tooltip; >+ button.setText(labelName); >+ button.setToolTipText(tooltip); >+ >+ if (infopop != null) >+ PlatformUI.getWorkbench().getHelpSystem().setHelp(button, JAXRSUIPlugin.PLUGIN_ID + "." + infopop); >+ >+ return button; >+ } >+ >+ private Button createCheckbox(Composite parent, String labelName, String tooltip, String infopop) >+ { >+ return createButton(SWT.CHECK, parent, labelName, tooltip, infopop); >+ } >+ >+ private Button createRadioButton(Composite parent, String labelName, String tooltip, String infopop) >+ { >+ return createButton(SWT.RADIO, parent, labelName, tooltip, infopop); >+ } >+ >+ >+ >+} >Index: src/org/eclipse/jst/ws/jaxrs/ui/internal/project/facet/JAXRSFacetInstallPage.java >=================================================================== >RCS file: /cvsroot/webtools/webservices/plugins/org.eclipse.jst.ws.jaxrs.ui/src/org/eclipse/jst/ws/jaxrs/ui/internal/project/facet/JAXRSFacetInstallPage.java,v >retrieving revision 1.7 >diff -u -r1.7 JAXRSFacetInstallPage.java >--- src/org/eclipse/jst/ws/jaxrs/ui/internal/project/facet/JAXRSFacetInstallPage.java 4 Mar 2010 03:49:55 -0000 1.7 >+++ src/org/eclipse/jst/ws/jaxrs/ui/internal/project/facet/JAXRSFacetInstallPage.java 10 Mar 2010 21:49:52 -0000 >@@ -13,6 +13,7 @@ > * 20091106 291954 ericdp@ca.ibm.com - Eric D. Peters, JAX-RS: Implement JAX-RS Facet > * 20100302 304405 ericdp@ca.ibm.com - Eric D. Peters, JAX-RS Facet : support JAX-RS 1.1 (JSR 311) > * 20100303 291954 kchong@ca.ibm.com - Keith Chong, JAX-RS: Implement JAX-RS Facet >+ * 20100310 291954 ericdp@ca.ibm.com - Eric D. Peters, JAX-RS: Implement JAX-RS Facet > *******************************************************************************/ > package org.eclipse.jst.ws.jaxrs.ui.internal.project.facet; > >@@ -27,6 +28,8 @@ > import org.eclipse.jface.dialogs.InputDialog; > import org.eclipse.jface.window.Window; > import org.eclipse.jst.common.project.facet.core.libprov.LibraryInstallDelegate; >+import org.eclipse.jst.common.project.facet.core.libprov.LibraryProviderOperationConfig; >+import org.eclipse.jst.common.project.facet.core.libprov.user.UserLibraryProviderInstallOperationConfig; > import org.eclipse.jst.common.project.facet.ui.libprov.LibraryProviderFrameworkUi; > import org.eclipse.jst.j2ee.project.EarUtilities; > import org.eclipse.jst.j2ee.project.facet.IJ2EEModuleFacetInstallDataModelProperties; >@@ -35,6 +38,8 @@ > import org.eclipse.jst.ws.jaxrs.core.internal.jaxrssharedlibraryconfig.SharedLibraryConfigurator; > import org.eclipse.jst.ws.jaxrs.core.internal.jaxrssharedlibraryconfig.SharedLibraryConfiguratorUtil; > import org.eclipse.jst.ws.jaxrs.core.internal.project.facet.IJAXRSFacetInstallDataModelProperties; >+import org.eclipse.jst.ws.jaxrs.core.internal.project.facet.IJAXRSSharedLibraryProviderInstallOperationConfig; >+import org.eclipse.jst.ws.jaxrs.core.internal.project.facet.JAXRSSharedLibraryProviderInstallOperationConfig; > import org.eclipse.jst.ws.jaxrs.core.internal.project.facet.JAXRSUserLibraryProviderInstallOperationConfig; > import org.eclipse.jst.ws.jaxrs.ui.internal.IJAXRSUIConstants; > import org.eclipse.jst.ws.jaxrs.ui.internal.JAXRSUIPlugin; >@@ -129,9 +134,15 @@ > composite.setLayout(jaxrsCompositeLayout); > > final LibraryInstallDelegate librariesInstallDelegate = (LibraryInstallDelegate) getDataModel().getProperty(LIBRARY_PROVIDER_DELEGATE); >- >- JAXRSUserLibraryProviderInstallOperationConfig customConfig = (JAXRSUserLibraryProviderInstallOperationConfig) librariesInstallDelegate.getLibraryProviderOperationConfig(); >- customConfig.setModel(getDataModel()); >+ LibraryProviderOperationConfig config = librariesInstallDelegate.getLibraryProviderOperationConfig(); >+ if (config instanceof JAXRSUserLibraryProviderInstallOperationConfig) { >+ JAXRSUserLibraryProviderInstallOperationConfig customConfig = (JAXRSUserLibraryProviderInstallOperationConfig) config ; >+ customConfig.setModel(getDataModel()); >+ } else if (config instanceof JAXRSSharedLibraryProviderInstallOperationConfig){ >+ JAXRSSharedLibraryProviderInstallOperationConfig customConfig = (JAXRSSharedLibraryProviderInstallOperationConfig) config ; >+ customConfig.setModel(getDataModel()); >+ } >+ > > final Control librariesComposite = LibraryProviderFrameworkUi.createInstallLibraryPanel(composite, librariesInstallDelegate, Messages.JAXRSFacetInstallPage_JAXRSImplementationLibrariesFrame); > >@@ -464,6 +475,16 @@ > { > if (event.getProperty() != null) > model.setStringProperty(TARGETRUNTIME, event.getProperty().toString()); >+ } else if (propertyName.equals(LIBRARY_PROVIDER_DELEGATE)) { >+ LibraryInstallDelegate librariesInstallDelegate = (LibraryInstallDelegate) getDataModel().getProperty(LIBRARY_PROVIDER_DELEGATE); >+ LibraryProviderOperationConfig config = librariesInstallDelegate.getLibraryProviderOperationConfig(); >+ if (config instanceof JAXRSUserLibraryProviderInstallOperationConfig) { >+ JAXRSUserLibraryProviderInstallOperationConfig customConfig = (JAXRSUserLibraryProviderInstallOperationConfig) config ; >+ customConfig.setModel(getDataModel()); >+ } else if (config instanceof JAXRSSharedLibraryProviderInstallOperationConfig){ >+ JAXRSSharedLibraryProviderInstallOperationConfig customConfig = (JAXRSSharedLibraryProviderInstallOperationConfig) config ; >+ customConfig.setModel(getDataModel()); >+ } > } > } > super.propertyChanged(event); >Index: src/org/eclipse/jst/ws/jaxrs/ui/internal/project/facet/JAXRSUserLibraryProviderInstallPanel.java >=================================================================== >RCS file: /cvsroot/webtools/webservices/plugins/org.eclipse.jst.ws.jaxrs.ui/src/org/eclipse/jst/ws/jaxrs/ui/internal/project/facet/JAXRSUserLibraryProviderInstallPanel.java,v >retrieving revision 1.2 >diff -u -r1.2 JAXRSUserLibraryProviderInstallPanel.java >--- src/org/eclipse/jst/ws/jaxrs/ui/internal/project/facet/JAXRSUserLibraryProviderInstallPanel.java 4 Mar 2010 03:49:55 -0000 1.2 >+++ src/org/eclipse/jst/ws/jaxrs/ui/internal/project/facet/JAXRSUserLibraryProviderInstallPanel.java 10 Mar 2010 21:49:52 -0000 >@@ -10,6 +10,7 @@ > * yyyymmdd bug Email and other contact information > * -------- -------- ----------------------------------------------------------- > * 20100303 291954 kchong@ca.ibm.com - Keith Chong, JAX-RS: Implement JAX-RS Facet >+ * 20100310 291954 ericdp@ca.ibm.com - Eric D. Peters, JAX-RS: Implement JAX-RS Facet > *******************************************************************************/ > package org.eclipse.jst.ws.jaxrs.ui.internal.project.facet; > >@@ -34,19 +35,14 @@ > import org.eclipse.swt.events.SelectionEvent; > import org.eclipse.swt.layout.GridData; > import org.eclipse.swt.layout.GridLayout; >-import org.eclipse.swt.widgets.Button; > import org.eclipse.swt.widgets.Composite; > import org.eclipse.swt.widgets.Control; >-import org.eclipse.ui.PlatformUI; > import org.eclipse.wst.common.frameworks.datamodel.DataModelFactory; > import org.eclipse.wst.common.frameworks.datamodel.IDataModel; > > public class JAXRSUserLibraryProviderInstallPanel extends UserLibraryProviderInstallPanel > { >- Button copyOnPublishCheckBox; >- private Composite includeLibRadiosComposite; >- private Button btnDeployJars; >- private Button btnSharedLibrary; >+ private JAXRSFacetIncludeLibrariesGroup includeLibsGroup; > private JAXRSLibraryConfigModel workingCopyModel = null; > private IDataModel model; > >@@ -69,55 +65,32 @@ > gl.marginRight = 0; > gl.marginLeft = 0; > mainComp.setLayout(gl); >+ includeLibsGroup = new JAXRSFacetIncludeLibrariesGroup(mainComp, SWT.NONE); >+ includeLibsGroup.getCopyOnPublishCheckBox().setSelection(cfg.isIncludeWithApplicationEnabled()); > >- copyOnPublishCheckBox = new Button(mainComp, SWT.CHECK); >- copyOnPublishCheckBox.setText(Messages.JAXRSLibraryConfigControl_IncludeGroupLabel); >- copyOnPublishCheckBox.setSelection(cfg.isIncludeWithApplicationEnabled()); >- >- includeLibRadiosComposite = new Composite(mainComp, SWT.NONE); >- GridLayout gridlayout = new GridLayout(); >- gridlayout.numColumns = 1; >- gridlayout.marginTop = 0; >- gridlayout.marginBottom = 0; >- gridlayout.marginRight = 0; >- gridlayout.marginLeft = 10; >- >- includeLibRadiosComposite.setLayout(gridlayout); >- GridData griddata = new GridData(GridData.FILL_HORIZONTAL); >- includeLibRadiosComposite.setLayoutData(griddata); > >- btnDeployJars = createRadioButton(includeLibRadiosComposite, Messages.JAXRSLibraryConfigControl_DeployButtonLabel, Messages.JAXRSLibraryConfigControl_DeployJAR, null); >- >- btnSharedLibrary = createRadioButton(includeLibRadiosComposite, Messages.JAXRSLibraryConfigControl_SharedLibButtonLabel, Messages.JAXRSLibraryConfigControl_TooltipIncludeAsSharedLib, null); >- >- copyOnPublishCheckBox.addSelectionListener(new SelectionAdapter() >+ includeLibsGroup.getCopyOnPublishCheckBox().addSelectionListener(new SelectionAdapter() > { > public void widgetSelected(final SelectionEvent event) > { >- cfg.setIncludeWithApplicationEnabled(copyOnPublishCheckBox.getSelection()); >- boolean selection = copyOnPublishCheckBox.getSelection(); >- btnDeployJars.setEnabled(selection); >- btnSharedLibrary.setEnabled(selection); >- >+ cfg.setIncludeWithApplicationEnabled(includeLibsGroup.getCopyOnPublishCheckBox().getSelection()); > } > }); > >- // Need to initialize this properly >- btnDeployJars.setSelection(true); > >- btnDeployJars.addSelectionListener(new SelectionAdapter() >+ includeLibsGroup.getBtnDeployJars().addSelectionListener(new SelectionAdapter() > { > public void widgetSelected(SelectionEvent e) > { > cfg.setIsDeploy(true); > cfg.setSharedLibrary(false); > IDataModel model = cfg.getModel(); >- model.setProperty(IJAXRSFacetInstallDataModelProperties.DEPLOY_IMPLEMENTATION, btnDeployJars.getSelection()); >- model.setProperty(IJAXRSFacetInstallDataModelProperties.SHAREDLIBRARY, btnSharedLibrary.getSelection()); >+ model.setProperty(IJAXRSFacetInstallDataModelProperties.DEPLOY_IMPLEMENTATION, includeLibsGroup.getBtnDeployJars().getSelection()); >+ model.setProperty(IJAXRSFacetInstallDataModelProperties.SHAREDLIBRARY, includeLibsGroup.getBtnDeployJars().getSelection()); > } > }); > >- btnSharedLibrary.addSelectionListener(new SelectionAdapter() >+ includeLibsGroup.getBtnSharedLibrary().addSelectionListener(new SelectionAdapter() > { > public void widgetSelected(SelectionEvent e) > { >@@ -127,8 +100,8 @@ > cfg.setIsDeploy(false); > cfg.setSharedLibrary(true); > IDataModel model = cfg.getModel(); >- model.setProperty(IJAXRSFacetInstallDataModelProperties.DEPLOY_IMPLEMENTATION, btnDeployJars.getSelection()); >- model.setProperty(IJAXRSFacetInstallDataModelProperties.SHAREDLIBRARY, btnSharedLibrary.getSelection()); >+ model.setProperty(IJAXRSFacetInstallDataModelProperties.DEPLOY_IMPLEMENTATION, includeLibsGroup.getBtnSharedLibrary().getSelection()); >+ model.setProperty(IJAXRSFacetInstallDataModelProperties.SHAREDLIBRARY, includeLibsGroup.getBtnSharedLibrary().getSelection()); > } > }); > >@@ -145,7 +118,7 @@ > > cfg.addListener(listener, JAXRSUserLibraryProviderInstallOperationConfig.PROP_INCLUDE_WITH_APPLICATION_ENABLED); > >- copyOnPublishCheckBox.addDisposeListener(new DisposeListener() >+ includeLibsGroup.getCopyOnPublishCheckBox().addDisposeListener(new DisposeListener() > { > public void widgetDisposed(final DisposeEvent event) > { >@@ -159,35 +132,11 @@ > } > > >- private Button createRadioButton(Composite parent, String labelName, String tooltip, String infopop) >- { >- return createButton(SWT.RADIO, parent, labelName, tooltip, infopop); >- } >- >- private Button createButton(int kind, Composite parent, String labelName, String tooltip, String infopop) >- { >- Button button = new Button(parent, kind); >- >- tooltip = tooltip == null ? labelName : tooltip; >- button.setText(labelName); >- button.setToolTipText(tooltip); >- >- if (infopop != null) >- PlatformUI.getWorkbench().getHelpSystem().setHelp(button, JAXRSUIPlugin.PLUGIN_ID + "." + infopop); >- >- return button; >- } >- >- private Button createCheckbox(Composite parent, String labelName, String tooltip, String infopop) >- { >- return createButton(SWT.CHECK, parent, labelName, tooltip, infopop); >- } >- > private void initialize() > { > // if shared lib not supported but shared lib setting was true, assume they > // still want to include libraries >- JAXRSLibraryConfiglModelSource source = new JAXRSLibraryConfigDialogSettingData(btnDeployJars.getSelection(), btnSharedLibrary.getSelection(), true); >+ JAXRSLibraryConfiglModelSource source = new JAXRSLibraryConfigDialogSettingData(includeLibsGroup.getBtnDeployJars().getSelection(), includeLibsGroup.getBtnSharedLibrary().getSelection(), true); > if (source != null) > { > // never read persistentModel = source; >@@ -247,13 +196,13 @@ > > private void updateChildrenState(JAXRSLibraryInternalReference selected) > { >- btnDeployJars.setSelection(selected.isCheckedToBeDeployed() || (copyOnPublishCheckBox.getSelection() && (!selected.isSharedLibSupported() || (selected.isSharedLibSupported() && !selected.isCheckedToBeSharedLibrary())))); >- // shared library has precedence >- btnSharedLibrary.setSelection(selected.isSharedLibSupported() && selected.isCheckedToBeSharedLibrary()); >- btnSharedLibrary.setEnabled(copyOnPublishCheckBox.getSelection() && selected.isSharedLibSupported()); >- btnDeployJars.setEnabled(copyOnPublishCheckBox.getSelection()); >- selected.setToBeDeployed(copyOnPublishCheckBox.getSelection() && btnDeployJars.getSelection()); >- selected.setToBeSharedLibrary(copyOnPublishCheckBox.getSelection() && selected.isSharedLibSupported() && btnSharedLibrary.getSelection()); >+// btnDeployJars.setSelection(selected.isCheckedToBeDeployed() || (copyOnPublishCheckBox.getSelection() && (!selected.isSharedLibSupported() || (selected.isSharedLibSupported() && !selected.isCheckedToBeSharedLibrary())))); >+// // shared library has precedence >+// btnSharedLibrary.setSelection(selected.isSharedLibSupported() && selected.isCheckedToBeSharedLibrary()); >+// btnSharedLibrary.setEnabled(copyOnPublishCheckBox.getSelection() && selected.isSharedLibSupported()); >+// btnDeployJars.setEnabled(copyOnPublishCheckBox.getSelection()); >+// selected.setToBeDeployed(copyOnPublishCheckBox.getSelection() && btnDeployJars.getSelection()); >+// selected.setToBeSharedLibrary(copyOnPublishCheckBox.getSelection() && selected.isSharedLibSupported() && btnSharedLibrary.getSelection()); > > } >
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 291954
: 161680