1 11 package org.eclipse.ant.internal.ui.editor.outline; 12 13 import org.eclipse.ant.internal.ui.AntUIImages; 14 import org.eclipse.ant.internal.ui.IAntUIConstants; 15 import org.eclipse.jface.action.Action; 16 import org.eclipse.swt.custom.BusyIndicator; 17 18 21 public class FilterImportedElementsAction extends Action { 22 23 private AntEditorContentOutlinePage fPage; 24 25 public FilterImportedElementsAction(AntEditorContentOutlinePage page) { 26 super(AntOutlineMessages.FilterImportedElementsAction_0); 27 fPage = page; 28 setImageDescriptor(AntUIImages.getImageDescriptor(IAntUIConstants.IMG_FILTER_IMPORTED_ELEMENTS)); 29 setToolTipText(AntOutlineMessages.FilterImportedElementsAction_0); 30 setChecked(fPage.filterImportedElements()); 31 } 32 33 37 public void run() { 38 BusyIndicator.showWhile(fPage.getControl().getDisplay(), new Runnable () { 39 public void run() { 40 fPage.setFilterImportedElements(isChecked()); 41 } 42 }); 43 } 44 } | Popular Tags |