From: Matti Tahvonen Date: Tue, 11 Aug 2009 10:05:20 +0000 (+0000) Subject: dropping support for gecko 1.7 (non oophm hosted mode under linux) X-Git-Tag: 6.7.0.beta1~2625 X-Git-Url: https://source.dussan.org/?a=commitdiff_plain;h=d81a80e397799ec143a3d25338dfc796ef6fedf2;p=vaadin-framework.git dropping support for gecko 1.7 (non oophm hosted mode under linux) svn changeset:8461/svn branch:6.1 --- diff --git a/src/com/vaadin/terminal/gwt/server/AbstractApplicationServlet.java b/src/com/vaadin/terminal/gwt/server/AbstractApplicationServlet.java index dd3fd19a1d..f952e78f94 100644 --- a/src/com/vaadin/terminal/gwt/server/AbstractApplicationServlet.java +++ b/src/com/vaadin/terminal/gwt/server/AbstractApplicationServlet.java @@ -1369,161 +1369,75 @@ public abstract class AbstractApplicationServlet extends HttpServlet { throw new ServletException("CommunicationError!", e); } - if (isGecko17(request)) { - // special start page for gecko 1.7 versions. Firefox 1.0 is not - // supported, but the hack is make it possible to use linux and - // hosted mode browser for debugging. Note that due this hack, - // debugging gwt code in portals with linux will be problematic if - // there are multiple Vaadin portlets visible at the same time. - // TODO remove this when hosted mode on linux gets newer gecko - - page.write("\n"); - page.write("\n"); - page.write("\n"); - - if (themeName != null) { - // Custom theme's stylesheet, load only once, in different - // script - // tag to be dominate styles injected by widget - // set - page.write("\n"); + String url = systemMessages.getCommunicationErrorURL(); + if (url != null) { + url = "\"" + url + "\""; } - } else { + page.write("\"comErrMsg\": {" + "\"caption\":" + caption + "," + + "\"message\" : " + message + "," + "\"url\" : " + url + + "}"); + } + page.write("};\n//]]>\n\n"); + + if (themeName != null) { + // Custom theme's stylesheet, load only once, in different + // script + // tag to be dominate styles injected by widget + // set page.write("\n"); - - if (themeName != null) { - // Custom theme's stylesheet, load only once, in different - // script - // tag to be dominate styles injected by widget - // set - page.write("\n"); - } + .write("document.getElementsByTagName('head')[0].appendChild(stylesheet);\n"); + page.write("vaadin.themesLoaded['" + themeName + "'] = true;\n}\n"); + page.write("//]]>\n\n"); } // Warn if the widgetset has not been loaded after 15 seconds on @@ -1583,18 +1497,6 @@ public abstract class AbstractApplicationServlet extends HttpServlet { return "You have to enable javascript in your browser to use an application built with Vaadin."; } - private boolean isGecko17(HttpServletRequest request) { - final WebBrowser browser = WebApplicationContext.getApplicationContext( - request.getSession()).getBrowser(); - if (browser != null && browser.getBrowserApplication() != null) { - if (browser.getBrowserApplication().indexOf("rv:1.7.") > 0 - && browser.getBrowserApplication().indexOf("Gecko") > 0) { - return true; - } - } - return false; - } - /** * Handles theme resource file requests. Resources supplied with the themes * are provided by the WebAdapterServlet.