Package org.waveprotocol.wave.media.model.Attachment

Examples of org.waveprotocol.wave.media.model.Attachment.ImageMetadata


   * Checks the values on the thumbnail and image metadata fields.
   *
   * @param wrapper the wrapper
   */
  private static void checkElementFields(MutableClientAttachment wrapper) {
    ImageMetadata attachmentImage = wrapper.getContentImageMetadata();
    assertEquals(IMAGE_HEIGHT, attachmentImage.getHeight());
    assertEquals(IMAGE_WIDTH, attachmentImage.getWidth());

    ImageMetadata attachmentThumbnail = wrapper.getThumbnailImageMetadata();
    assertEquals(THUMB_HEIGHT, attachmentThumbnail.getHeight());
    assertEquals(THUMB_WIDTH, attachmentThumbnail.getWidth());
  }
View Full Code Here


    String url = c.getAttachmentUrl();
    if (url != null) {
      renderer.getView(e).setAttachmentUrl(url);
    }

    ImageMetadata metadata = c.getContentImageMetadata();
    if (metadata != null) {
      renderer.getView(e).setAttachmentSize(metadata.getWidth(), metadata.getHeight());
    }
  }
View Full Code Here

    String url = c.getThumbnailUrl();
    if (url != null) {
      renderer.getView(e).setThumbnailUrl(url);
    }

    ImageMetadata metadata = c.getThumbnailImageMetadata();
    if (metadata != null) {
      renderer.getView(e).setThumbnailSize(metadata.getWidth(), metadata.getHeight());
    }

    if (metadata == null && c.getStatus() == Status.FAILED_AND_NOT_RETRYABLE) {
      renderer.getView(e).displayDeadImage(
          attachmentLoadingFailedTooltip);
View Full Code Here

TOP

Related Classes of org.waveprotocol.wave.media.model.Attachment.ImageMetadata

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.