1 11 package org.eclipse.jdt.internal.debug.ui.variables; 12 13 import org.eclipse.core.runtime.Preferences.IPropertyChangeListener; 14 import org.eclipse.core.runtime.Preferences.PropertyChangeEvent; 15 import org.eclipse.debug.ui.IDebugView; 16 import org.eclipse.jdt.internal.debug.ui.SWTFactory; 17 import org.eclipse.jface.action.IAction; 18 import org.eclipse.jface.viewers.ISelection; 19 import org.eclipse.ui.IViewActionDelegate; 20 import org.eclipse.ui.IViewPart; 21 22 25 public class VariableOptionsAction implements IViewActionDelegate, IPropertyChangeListener { 26 27 private IViewPart fPart; 28 29 32 public void init(IViewPart view) { 33 fPart = view; 34 } 35 36 39 public void run(IAction action) { 40 SWTFactory.showPreferencePage("org.eclipse.jdt.debug.ui.JavaDetailFormattersPreferencePage", new String [] {"org.eclipse.jdt.debug.ui.JavaDetailFormattersPreferencePage", "org.eclipse.jdt.debug.ui.JavaLogicalStructuresPreferencePage", "org.eclipse.jdt.debug.ui.heapWalking", "org.eclipse.jdt.debug.ui.JavaPrimitivesPreferencePage"}); } 46 47 50 public void selectionChanged(IAction action, ISelection selection) { 51 } 52 53 56 public void propertyChange(PropertyChangeEvent event) { 57 if (fPart instanceof IDebugView) { 58 IDebugView view = (IDebugView) fPart; 59 view.getViewer().refresh(); 60 } 61 62 } 63 64 } 65 | Popular Tags |