Package com.vaadin.terminal

Examples of com.vaadin.terminal.ExternalResource


//            for (int i =0; i < buttonLayout.getComponentCount(); i++) {
//                buttonLayout.setComponentAlignment(buttonLayout.getComponent(i), Alignment.BOTTOM_LEFT);
//            }
            if (metadata.getHomepageUrl() != null) {
                Link c = new Link(getLocalizedMessage("plugins.console.plugin.homepage"), new ExternalResource( metadata.getHomepageUrl()));
                c.setTargetName("_blank");
                buttonLayout.addComponent(c);
            }
            if (metadata.getDocumentationUrl() != null) {
                Link c = new Link(getLocalizedMessage("plugins.console.plugin.documentation"),
                        new ExternalResource( metadata.getDocumentationUrl()));
                c.setTargetName("_blank");
                buttonLayout.addComponent(c);
            }
            bundleList.addComponent(verticalLayout(
                    styled(new Label(metadata.getId() + ": " + metadata.getName() + " (" + metadata.getVersion() + ")"), "h2"),
View Full Code Here


                                            newContent.setSpacing(false);
                                            w.setContent(newContent);
                                            w.getContent().setWidth(read.getWidth() + "px");
                                            w.getContent().setHeight(read.getHeight() + "px");
                                            w.center();
                                            Embedded e = new Embedded(null, new ExternalResource(url));
                                            e.setWidth(read.getWidth() + "px");
                                            e.setHeight(read.getHeight() + "px");
                                            e.setType(Embedded.TYPE_BROWSER);
                                            w.getContent().addComponent(e);
                                            w.setResizable(true);
View Full Code Here

    if(url.matches("#\\{.*\\}")){
          String urlKey = url.replaceAll("#\\{(.*)\\}", "$1");
          if(processAttributes.containsKey(urlKey))
            url = ((ProcessInstanceSimpleAttribute)processAttributes.get(urlKey)).getValue();
        }
        link.setResource(new ExternalResource(url));
        return link;
    }
View Full Code Here

          String urlKey = url.replaceAll("#\\{(.*)\\}", "$1");
          ProcessInstanceAttribute attr = task.getProcessInstance().findAttributeByKey(urlKey);
          if(attr != null)
            url = ((ProcessInstanceSimpleAttribute)attr).getValue();
        }
        getApplication().getMainWindow().open(new ExternalResource(url), "_new");
    }
View Full Code Here

    linkLayout.addComponent(new Embedded(null, getImage(attachment)));
   
    // Link
    Link link = null;
    if(attachment.getUrl() != null) {
      link = new Link(attachment.getUrl(), new ExternalResource(attachment.getUrl()));
    } else {
      TaskService taskService = ProcessEngines.getDefaultProcessEngine().getTaskService();
      Resource res = new StreamResource(new InputStreamStreamSource(taskService.getAttachmentContent(attachment.getId())),
              attachment.getName() + extractExtention(attachment.getType()),ExplorerApp.get());
     
View Full Code Here

      addProfileInputField(contactLayout, i18nManager.getMessage(Messages.PROFILE_PHONE), phoneField, phone);
    }
   
    // Twitter
    if (!editable && isDefined(twitterName)) {
      Link twitterLink = new Link(twitterName, new ExternalResource("http://www.twitter.com/"+twitterName));
      addProfileEntry(contactLayout, i18nManager.getMessage(Messages.PROFILE_TWITTER), twitterLink);
    } else if (editable) {
      twitterField = new TextField();
      addProfileInputField(contactLayout, i18nManager.getMessage(Messages.PROFILE_TWITTER), twitterField, twitterName);
    }
View Full Code Here

          parent.showAttachmentDetail(attachment);
        }
      });
      return attachmentLink;
    } else {
      return new Link(attachment.getName(), new ExternalResource(attachment.getUrl()));
    }
  }
View Full Code Here

   
    // Icon
    linkLayout.addComponent(new Embedded(null, Images.RELATED_CONTENT_URL));
   
    // Link
    Link link = new Link(attachment.getUrl(), new ExternalResource(attachment.getUrl()));
    link.setTargetName(ExplorerLayout.LINK_TARGET_BLANK);
    linkLayout.addComponent(link);
   
    return verticalLayout;
  }
View Full Code Here

    Label fullSizeLabel = new Label(ExplorerApp.get().getI18nManager().getMessage(Messages.RELATED_CONTENT_SHOW_FULL_SIZE));
    LinkLayout.addComponent(fullSizeLabel);
   
    Link link = null;
    if(attachment.getUrl() != null) {
      link = new Link(attachment.getUrl(), new ExternalResource(attachment.getUrl()));
    } else {
      taskService = ProcessEngines.getDefaultProcessEngine().getTaskService();
      Resource res = new StreamResource(new InputStreamStreamSource(taskService.getAttachmentContent(attachment.getId())),
              attachment.getName() + extractExtention(attachment.getType()),ExplorerApp.get());
     
View Full Code Here

   
    this.modelId = modelId;
  }

  public void buttonClick(ClickEvent event) {
    ExplorerApp.get().getMainWindow().open(new ExternalResource(
        ExplorerApp.get().getURL().toString() + "service/editor?id=" + modelId));
  }
View Full Code Here

TOP

Related Classes of com.vaadin.terminal.ExternalResource

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.