1 20 21 package org.apache.directory.ldapstudio.browser.ui.actions; 22 23 24 import org.apache.directory.ldapstudio.browser.ui.BrowserUIConstants; 25 import org.apache.directory.ldapstudio.browser.ui.BrowserUIPlugin; 26 import org.eclipse.jface.action.Action; 27 import org.eclipse.jface.viewers.TreeViewer; 28 29 30 36 public class ExpandAllAction extends Action 37 { 38 protected TreeViewer viewer; 39 40 41 47 public ExpandAllAction( TreeViewer viewer ) 48 { 49 super( "Expand All", BrowserUIPlugin.getDefault().getImageDescriptor( BrowserUIConstants.IMG_EXPANDALL ) ); 50 super.setToolTipText( getText() ); 51 super.setEnabled( true ); 52 53 this.viewer = viewer; 54 } 55 56 57 60 public void run() 61 { 62 this.viewer.expandAll(); 63 } 64 65 66 69 public void dispose() 70 { 71 this.viewer = null; 72 } 73 } 74 | Popular Tags |