1
0
Fork 0
mirror of https://github.com/eclipse-cdt/cdt synced 2025-07-24 09:25:31 +02:00

[225617] fix: [useraction][api] Remove Team view support inside user action.

This commit is contained in:
Xuan Chen 2008-04-03 18:33:56 +00:00
parent b9ec436896
commit 3474322cef
2 changed files with 3 additions and 16 deletions

View file

@ -11,12 +11,12 @@ package org.eclipse.rse.internal.useractions.ui.uda.actions;
* IBM Corporation - initial API and implementation
* David Dykstal (IBM) - [186589] move user types, user actions, and compile commands
* API to the user actions plugin
* Xuan Chen (IBM) - [225617] [useraction][api] Remove Team view support inside user action.
*******************************************************************************/
import org.eclipse.jface.dialogs.Dialog;
import org.eclipse.rse.core.model.ISystemProfile;
import org.eclipse.rse.core.subsystems.ISubSystem;
import org.eclipse.rse.core.subsystems.ISubSystemConfiguration;
import org.eclipse.rse.internal.ui.view.team.SystemTeamViewSubSystemConfigurationNode;
import org.eclipse.rse.internal.useractions.IUserActionsImageIds;
import org.eclipse.rse.internal.useractions.ui.uda.SystemUDAResources;
import org.eclipse.rse.internal.useractions.ui.uda.SystemUDActionSubsystem;
@ -112,11 +112,6 @@ public class SystemWorkWithFileTypesAction extends SystemBaseDialogAction {
protected Dialog createDialog(Shell parent) {
if ((subsystem == null) && (getFirstSelection() instanceof ISubSystem))
subsystem = (ISubSystem) getFirstSelection();
else if (getFirstSelection() instanceof SystemTeamViewSubSystemConfigurationNode) {
SystemTeamViewSubSystemConfigurationNode ssfNode = (SystemTeamViewSubSystemConfigurationNode) getFirstSelection();
subsystemFactory = ssfNode.getSubSystemConfiguration();
profile = ssfNode.getProfile();
}
if (subsystem != null)
ourDlg = new SystemWorkWithUDTypeDialog(parent, subsystem, udaActionSubsystem);
else

View file

@ -11,6 +11,7 @@ package org.eclipse.rse.internal.useractions.ui.uda.actions;
* IBM Corporation - initial API and implementation
* David Dykstal (IBM) - [186589] move user types, user actions, and compile commands
* API to the user actions plugin
* Xuan Chen (IBM) - [225617] [useraction][api] Remove Team view support inside user action.
*******************************************************************************/
//import java.util.Iterator;
import org.eclipse.jface.dialogs.Dialog;
@ -18,7 +19,6 @@ import org.eclipse.jface.viewers.IStructuredSelection;
import org.eclipse.rse.core.model.ISystemProfile;
import org.eclipse.rse.core.subsystems.ISubSystem;
import org.eclipse.rse.core.subsystems.ISubSystemConfiguration;
import org.eclipse.rse.internal.ui.view.team.SystemTeamViewSubSystemConfigurationNode;
import org.eclipse.rse.internal.useractions.IUserActionsImageIds;
import org.eclipse.rse.internal.useractions.ui.uda.SystemUDAResources;
import org.eclipse.rse.internal.useractions.ui.uda.SystemUDActionSubsystem;
@ -129,15 +129,7 @@ public class SystemWorkWithUDAsAction extends SystemBaseDialogAction {
* Our opportunity to verify we are allowed for this selected type.
*/
public boolean updateSelection(IStructuredSelection selection) {
boolean enable = true;
Object firstSelection = selection.getFirstElement();
if (firstSelection instanceof SystemTeamViewSubSystemConfigurationNode) {
SystemTeamViewSubSystemConfigurationNode ssfNode = (SystemTeamViewSubSystemConfigurationNode) firstSelection;
subsystemFactory = ssfNode.getSubSystemConfiguration();
profile = ssfNode.getProfile();
enable = profile.isActive();
}
return enable;
return true;
}
/**