Package jfix.zk

Examples of jfix.zk.Image


import org.apache.commons.io.FileUtils;

public class NodeViews {

  public static View asType(Node node) {
    return new View(node.getType(), new Row(new Image(JeaseSession
        .getConfig().getIcon(node)), new Label(node.getType())));
  }
View Full Code Here


    return new View(node.getType(), new Row(new Image(JeaseSession
        .getConfig().getIcon(node)), new Label(node.getType())));
  }
 
  public static View asIcon(Node node) {
    Image image = new Image();
    image.setSrc(JeaseSession.getConfig().getIcon(node));
    image.setTooltiptext(node.getType());
    return new View(node.getType(), image);
  }
View Full Code Here

  }

  private void appendControls() {
    remove(controls);
    add("", controls);
    Image trash = new Image(Images.UserTrashFull);
    trash.setDroppable(toString());
    trash.addEventListener(Events.ON_DROP, new EventListener() {
      public void onEvent(Event evt) throws Exception {
        DropEvent dropEvent = (DropEvent) evt;
        getRows().removeChild(
            dropEvent.getDragged().getParent().getParent());
      }
    });
    trash.setParent(controls.getParent().getPreviousSibling());
    augmentLablesForEditing();
  }
View Full Code Here

  }

  private Popup newNodePreview(Node node) {
    String id = node.getId();
    if (id.endsWith(".jpg") || id.endsWith(".png") || id.endsWith(".gif")) {
      return new Popup(new Image(node.getPath()));
    } else {
      return null;
    }
  }
View Full Code Here

TOP

Related Classes of jfix.zk.Image

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.