diff options
author | Artur Signell <artur@vaadin.com> | 2013-04-18 00:52:33 +0300 |
---|---|---|
committer | Vaadin Code Review <review@vaadin.com> | 2013-04-18 06:50:33 +0000 |
commit | 8fcad2fe496d04b4f4fa6e8eebee673226fe70d4 (patch) | |
tree | c62f3b8e8a4e9fd9bd7220f11c7c1af49ef9ad9a /server/src | |
parent | fb422a20d7c2e098ca891f79a9a883d8856edb9b (diff) | |
download | vaadin-framework-8fcad2fe496d04b4f4fa6e8eebee673226fe70d4.tar.gz vaadin-framework-8fcad2fe496d04b4f4fa6e8eebee673226fe70d4.zip |
Restrict longer padding to IE8 as Chrome fails without the original padding (#11573)
Change-Id: I00742d66052e318a023ed8ec2e3e5afbc7a3199f
Diffstat (limited to 'server/src')
-rw-r--r-- | server/src/com/vaadin/server/communication/PushHandler.java | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/server/src/com/vaadin/server/communication/PushHandler.java b/server/src/com/vaadin/server/communication/PushHandler.java index 0057a71c83..f65a0cba10 100644 --- a/server/src/com/vaadin/server/communication/PushHandler.java +++ b/server/src/com/vaadin/server/communication/PushHandler.java @@ -36,6 +36,7 @@ import com.vaadin.server.VaadinService; import com.vaadin.server.VaadinServletRequest; import com.vaadin.server.VaadinServletService; import com.vaadin.server.VaadinSession; +import com.vaadin.server.WebBrowser; import com.vaadin.ui.UI; /** @@ -104,8 +105,12 @@ public class PushHandler implements AtmosphereHandler { "text/plain; charset=UTF-8"); if (resource.transport() == TRANSPORT.STREAMING) { // IE8 requires a longer padding to work properly if the - // initial message is small (#11573) - resource.padding(LONG_PADDING); + // initial message is small (#11573). Chrome does not work + // without the original padding... + WebBrowser browser = session.getBrowser(); + if (browser.isIE() && browser.getBrowserMajorVersion() == 8) { + resource.padding(LONG_PADDING); + } } resource.suspend(); |