From 0af15f64a1143c5fa030b1837389bb4122195f77 Mon Sep 17 00:00:00 2001 From: Artur Signell Date: Tue, 26 Aug 2014 21:29:04 +0300 Subject: Add theme class name in init to prevent delay for embedded apps (#14517) Change-Id: I73bf41ca493f76d0a4caa82464ef3c63b3d7f055 --- client/src/com/vaadin/client/ui/ui/UIConnector.java | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/client/src/com/vaadin/client/ui/ui/UIConnector.java b/client/src/com/vaadin/client/ui/ui/UIConnector.java index c88fd23eca..d6f14bf158 100644 --- a/client/src/com/vaadin/client/ui/ui/UIConnector.java +++ b/client/src/com/vaadin/client/ui/ui/UIConnector.java @@ -494,7 +494,11 @@ public class UIConnector extends AbstractSingleComponentContainerConnector // the user root.getElement().setInnerHTML(""); + // Activate the initial theme by only adding the class name. Not calling + // activateTheme here as it will also cause a full layout and updates to + // the overlay container which has not yet been created at this point activeTheme = applicationConnection.getConfiguration().getThemeName(); + root.addStyleName(activeTheme); root.add(getWidget()); -- cgit v1.2.3