1 11 package org.eclipse.ui.internal.navigator.workingsets; 12 13 import org.eclipse.jface.viewers.ILabelProvider; 14 import org.eclipse.jface.viewers.ILabelProviderListener; 15 import org.eclipse.swt.graphics.Image; 16 import org.eclipse.ui.IWorkingSet; 17 import org.eclipse.ui.model.WorkbenchLabelProvider; 18 19 23 public class WorkingSetsLabelProvider implements ILabelProvider { 24 25 private WorkbenchLabelProvider labelProvider = new WorkbenchLabelProvider(); 26 27 public Image getImage(Object element) { 28 if (element instanceof IWorkingSet) 29 return labelProvider.getImage(element); 30 return null; 31 } 32 33 public String getText(Object element) { 34 if (element instanceof IWorkingSet) 35 return ((IWorkingSet) element).getLabel(); 36 return null; 37 } 38 39 public void addListener(ILabelProviderListener listener) { 40 42 } 43 44 public void dispose() { 45 47 } 48 49 public boolean isLabelProperty(Object element, String property) { 50 return false; 52 } 53 54 public void removeListener(ILabelProviderListener listener) { 55 57 } 58 59 } 60 | Popular Tags |