Package org.jayasoft.woj.client.views.contentProvider

Examples of org.jayasoft.woj.client.views.contentProvider.Node


        Image packageImg = WojPlugin.getImageDescriptor("icons/package_obj.gif").createImage(); //$NON-NLS-1$

        public Image getImage(Object element) {
          if (element instanceof Node) {
            Node node = (Node) element;
            if (node.hasChilds()) {
              return packageImg;
            } else {
              return classImg;
            }
          }
View Full Code Here


    if (classViewer != null) {
      Object firstSel = ((StructuredSelection) classViewer.getSelection()).getFirstElement();
      if (firstSel instanceof String) {
        return (String) firstSel;
      } else if (firstSel instanceof Node) {
        Node node = ((Node) firstSel);
        if (!node.hasChilds()) {
          return node.getFullPath();
        }
      }
    }
    return null;
  }
View Full Code Here

  private SashForm _sashForm;

  public static class NameSorter extends ViewerSorter {
    public int compare(Viewer viewer, Object e1, Object e2) {
      if (e1 instanceof Node && e2 instanceof Node) {
        Node n1 = (Node) e1;
        Node n2 = (Node) e2;
        return n1.compareTo(n2);
      }
      return super.compare(viewer, e1, e2);
    }
View Full Code Here

TOP

Related Classes of org.jayasoft.woj.client.views.contentProvider.Node

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.