aboutsummaryrefslogtreecommitdiffstats
path: root/server/src/com/vaadin/ui
diff options
context:
space:
mode:
authorArtur Signell <artur@vaadin.com>2012-11-21 11:52:22 +0000
committerVaadin Code Review <review@vaadin.com>2012-11-21 11:52:22 +0000
commit8af6628891f519f319b1bd122e60207bcb013901 (patch)
tree0aa769fc0f2298d10169c2d97e14b6164e930db0 /server/src/com/vaadin/ui
parent3fc9f19534b7d1ab06fc73b146b9d31868c205c1 (diff)
parent7d9c4c5e06a95f4aa5eb371a2f5b5418b92fac64 (diff)
downloadvaadin-framework-8af6628891f519f319b1bd122e60207bcb013901.tar.gz
vaadin-framework-8af6628891f519f319b1bd122e60207bcb013901.zip
Merge "Reomove DynamicConnectorResource (#10227)"
Diffstat (limited to 'server/src/com/vaadin/ui')
-rw-r--r--server/src/com/vaadin/ui/LoginForm.java15
1 files changed, 13 insertions, 2 deletions
diff --git a/server/src/com/vaadin/ui/LoginForm.java b/server/src/com/vaadin/ui/LoginForm.java
index b1e4741450..9c131b9700 100644
--- a/server/src/com/vaadin/ui/LoginForm.java
+++ b/server/src/com/vaadin/ui/LoginForm.java
@@ -22,7 +22,8 @@ import java.util.HashMap;
import java.util.Iterator;
import java.util.Map;
-import com.vaadin.server.DynamicConnectorResource;
+import com.vaadin.server.ConnectorResource;
+import com.vaadin.server.ExternalResource;
import com.vaadin.server.VaadinRequest;
import com.vaadin.server.VaadinResponse;
import com.vaadin.server.VaadinService;
@@ -108,12 +109,22 @@ public class LoginForm extends CustomComponent {
public LoginForm() {
iframe.setType(Embedded.TYPE_BROWSER);
iframe.setSizeFull();
- iframe.setSource(new DynamicConnectorResource(this, "login"));
setSizeFull();
setCompositionRoot(iframe);
addStyleName("v-loginform");
}
+ @Override
+ public void beforeClientResponse(boolean initial) {
+ // Generate magic URL now when UI id and connectorId are known
+ iframe.setSource(new ExternalResource(
+ ApplicationConstants.APP_PROTOCOL_PREFIX
+ + ApplicationConstants.APP_REQUEST_PATH + '/'
+ + ConnectorResource.CONNECTOR_REQUEST_PATH
+ + getUI().getUIId() + '/' + getConnectorId() + "/login"));
+ super.beforeClientResponse(initial);
+ }
+
/**
* Returns byte array containing login page html. If you need to override
* the login html, use the default html as basis. Login page sets its target