Examples of SharedResourceReference


Examples of org.apache.wicket.request.resource.SharedResourceReference

    if (css != null)
    {
      response.render(CssHeaderItem.forReference(css));
    }

    ResourceReference ref = new SharedResourceReference(RESOURCE_NAME);

    final String uploadFieldId = (uploadField == null) ? "" : uploadField.getMarkupId();

    final String status = new StringResourceModel(RESOURCE_STARTING, this, (IModel<?>)null).getString();
View Full Code Here

Examples of org.apache.wicket.request.resource.SharedResourceReference

  /**
   * @throws Exception
   */
  public void testResourceReferenceUrl() throws Exception
  {
    ResourceReference rr = new SharedResourceReference("test");
    CharSequence url = tester.getRequestCycle().urlFor(rr).toString();
    assertEquals("wicket/resource/org.apache.wicket.Application/test", url);

    rr = new PackageResourceReference(SharedResourceUrlTest.class, "test");
    url = tester.getRequestCycle().urlFor(rr).toString();
View Full Code Here

Examples of org.apache.wicket.request.resource.SharedResourceReference

  /**
   * @throws Exception
   */
  public void testResourceReferenceWithParamsUrl() throws Exception
  {
    ResourceReference rr = new SharedResourceReference("test");
    CharSequence url = tester.getRequestCycle().urlFor(rr,
      new PageParameters("param=value", "")).toString();
    assertEquals("wicket/resource/org.apache.wicket.Application/test?param=value", url);

    rr = new PackageResourceReference(SharedResourceUrlTest.class, "test");
View Full Code Here

Examples of org.apache.wicket.request.resource.SharedResourceReference

      PopupSettings.SCROLLBARS).setHeight(500).setWidth(700);
    add(new ExternalLink("googlePopup", "http://www.google.com",
      "Click this link to go to Google in a popup").setPopupSettings(googlePopupSettings));

    // Shared resource link
    add(new ResourceLink("cancelButtonLink", new SharedResourceReference("cancelButton")));

    // redirect to external url form
    FeedbackPanel feedbackPanel = new FeedbackPanel("feedback");
    add(feedbackPanel);
    add(new RedirectForm("redirectForm"));
View Full Code Here

Examples of org.apache.wicket.request.resource.SharedResourceReference

    }

    @Override
    public void onComponentTag(Component component, ComponentTag tag)
    {
      ResourceReference ref = new SharedResourceReference(RESOURCE_NAME);
      final String uploadFieldId = (uploadField == null) ? "" : uploadField.getMarkupId();
      tag.put("onsubmit", "var def=new Wicket.WUPB.Def('" + component.getMarkupId() + "', '" +
        status.getMarkupId() + "', '" + bar.getMarkupId() + "', '" +
        component.getPage().urlFor(ref) + "','" + uploadFieldId +
        "'); Wicket.WUPB.start(def);");
View Full Code Here

Examples of org.apache.wicket.request.resource.SharedResourceReference

      PopupSettings.SCROLLBARS).setHeight(500).setWidth(700);
    add(new ExternalLink("googlePopup", "http://www.google.com",
      "Click this link to go to Google in a popup").setPopupSettings(googlePopupSettings));

    // Shared resource link
    add(new ResourceLink("cancelButtonLink", new SharedResourceReference("cancelButton")));

    // redirect to external url form
    FeedbackPanel feedbackPanel = new FeedbackPanel("feedback");
    add(feedbackPanel);
    add(new RedirectForm("redirectForm"));
View Full Code Here

Examples of org.apache.wicket.request.resource.SharedResourceReference

  /**
   * @throws Exception
   */
  public void testResourceReferenceUrl() throws Exception
  {
    ResourceReference rr = new SharedResourceReference("test");
    CharSequence url = tester.getRequestCycle().mapUrlFor(rr, null).toString();
    assertEquals("wicket/resource/org.apache.wicket.Application/test", url);

    rr = new PackageResourceReference(SharedResourceUrlTest.class, "test");
    url = tester.getRequestCycle().mapUrlFor(rr, null).toString();
View Full Code Here

Examples of org.apache.wicket.request.resource.SharedResourceReference

  /**
   * @throws Exception
   */
  public void testResourceReferenceWithParamsUrl() throws Exception
  {
    ResourceReference rr = new SharedResourceReference("test");
    CharSequence url = tester.getRequestCycle()
      .mapUrlFor(rr, new PageParameters().set("param", "value"))
      .toString();
    assertEquals("wicket/resource/org.apache.wicket.Application/test?param=value", url);

View Full Code Here

Examples of org.apache.wicket.request.resource.SharedResourceReference

  {
    super.setUp();

    resource = new TestResource();
    tester.getApplication().getSharedResources().add(SHARED_NAME, resource);
    ResourceReference resourceReference = new SharedResourceReference(SHARED_NAME);
    mapper = new ResourceMapper("/test/resource", resourceReference);
    tester.getApplication().getRootRequestMapperAsCompound().add(mapper);
  }
View Full Code Here

Examples of org.apache.wicket.request.resource.SharedResourceReference

    // Add okay button image
    add(new Image("okButton", getOkButtonImage()));

    // Add cancel button image
    add(new Image("cancelButton", new SharedResourceReference("cancelButton")));

    // image loaded as resource ref via model.
    add(new Image("imageModelResourceReference", new Model<>(RESOURCE_REF)));

    // image loaded as resource via model.
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.