1
0
Fork 0
mirror of https://github.com/eclipse-cdt/cdt synced 2025-04-23 14:42:11 +02:00

Bug 236857

This commit is contained in:
Ken Ryall 2009-01-23 02:40:22 +00:00
parent 90285d927f
commit cbcbc74c30

View file

@ -85,7 +85,7 @@ public class EnableVariablesActionDelegate implements IViewActionDelegate {
public void run() { public void run() {
while( it.hasNext() ) { while( it.hasNext() ) {
IEnableDisableTarget target = getEnableDisableTarget( it.next() ); IEnableDisableTarget target = getEnableDisableTarget( it.next() );
if ( target != null ) { if ( target != null && target.canEnableDisable() ) {
try { try {
if ( size > 1 ) { if ( size > 1 ) {
target.setEnabled( isEnableAction() ); target.setEnabled( isEnableAction() );
@ -124,12 +124,12 @@ public class EnableVariablesActionDelegate implements IViewActionDelegate {
boolean allDisabled = true; boolean allDisabled = true;
while( it.hasNext() ) { while( it.hasNext() ) {
IEnableDisableTarget target = getEnableDisableTarget( it.next() ); IEnableDisableTarget target = getEnableDisableTarget( it.next() );
if ( target != null && !target.canEnableDisable() ) if ( target != null && target.canEnableDisable() ) {
continue; if ( target.isEnabled() )
if ( target.isEnabled() ) allDisabled = false;
allDisabled = false; else
else allEnabled = false;
allEnabled = false; }
} }
if ( isEnableAction() ) if ( isEnableAction() )
action.setEnabled( !allEnabled ); action.setEnabled( !allEnabled );