Package org.apache.wicket.protocol.http.request

Examples of org.apache.wicket.protocol.http.request.WebClientInfo


    String to = parameters.get("cto").toString();
    setContinueTo(to);
    initComps();
    RequestCycle requestCycle = getRequestCycle();
    WebSession session = (WebSession)getSession();
    WebClientInfo clientInfo = session.getClientInfo();
    if (clientInfo == null)
    {
      clientInfo = new WebClientInfo(requestCycle);
      getSession().setClientInfo(clientInfo);
    }
    else
    {
      ClientProperties properties = clientInfo.getProperties();
      properties.setJavaEnabled(false);
    }
    continueToPrevious();
  }
View Full Code Here


    String utcDSTOffset = requestParameters.getParameterValue("utcDSTOffset").toString("N/A");
    int browserWidth = requestParameters.getParameterValue("browserWidth").toInt(-1);
    int browserHeight = requestParameters.getParameterValue("browserHeight").toInt(-1);
    String hostname = requestParameters.getParameterValue("hostname").toString("N/A");

    WebClientInfo clientInfo = new WebClientInfo(requestCycle);
    Session.get().setClientInfo(clientInfo);

    ClientProperties properties = clientInfo.getProperties();
    properties.setNavigatorAppCodeName(navigatorAppCodeName);
    properties.setNavigatorAppName(navigatorAppName);
    properties.setNavigatorAppVersion(navigatorAppVersion);
    properties.setCookiesEnabled(navigatorCookieEnabled);
    properties.setJavaEnabled(navigatorJavaEnabled);
View Full Code Here

        // if we get here, the redirect already has been done; clear
        // the meta data entry; we don't need it any longer is the client
        // info object will be cached too
        setMetaData(BROWSER_WAS_POLLED_KEY, null);
      }
      clientInfo = new WebClientInfo(requestCycle);
    }
    return (WebClientInfo)clientInfo;
  }
View Full Code Here

      // if we get here, the redirect already has been done; clear
      // the meta data entry; we don't need it any longer is the client
      // info object will be cached too
      session.setMetaData(BROWSER_WAS_POLLED_KEY, (Boolean)null);
    }
    return new WebClientInfo(this);
  }
View Full Code Here

  {
    RequestCycle requestCycle = RequestCycle.get();
    String name = requestCycle.getMetaData(KEY);
    if (name == null)
    {
      WebClientInfo clientInfo;
      name = getVersion2();
      if (Session.exists())
      {
        WebSession session = WebSession.get();
        clientInfo = session.getClientInfo();
      }
      else
      {
        clientInfo = new WebClientInfo(requestCycle);
      }
      ClientProperties clientProperties = clientInfo.getProperties();
      if (clientProperties.isBrowserInternetExplorer() && clientProperties.getBrowserVersionMajor() < 9)
      {
        name = getVersion1();
      }
View Full Code Here

        if(applicationJs != null) {
            response.render(JavaScriptReferenceHeaderItem.forUrl(applicationJs));
        }

        // TODO mgrigorov Remove before merge to master
        WebClientInfo clientInfo = WebSession.get().getClientInfo();
        ClientProperties properties = clientInfo.getProperties();
        if (!(properties.isBrowserInternetExplorer() && properties.getBrowserVersionMajor() < 9)) {
            // use BootLint for any browser but IE 6-8
            response.render(JavaScriptHeaderItem.forReference(BootlintJavaScriptReference.INSTANCE));
        }
    }
View Full Code Here

  {
    RequestCycle requestCycle = RequestCycle.get();
    String name = requestCycle.getMetaData(KEY);
    if (name == null)
    {
      WebClientInfo clientInfo;
      name = getVersion2();
      if (Session.exists())
      {
        WebSession session = WebSession.get();
        clientInfo = session.getClientInfo();
      }
      else
      {
        clientInfo = new WebClientInfo(requestCycle);
      }
      ClientProperties clientProperties = clientInfo.getProperties();
      if (clientProperties.isBrowserInternetExplorer() && clientProperties.getBrowserVersionMajor() < 9)
      {
        name = getVersion1();
      }
View Full Code Here

        WebSession session = (WebSession)getSession();
        ClientInfo clientInfo = session.getClientInfo();

        if (clientInfo == null)
        {
          clientInfo = new WebClientInfo(requestCycle);
          getSession().setClientInfo(clientInfo);
        }

        if (clientInfo instanceof WebClientInfo)
        {
          WebClientInfo info = (WebClientInfo)clientInfo;
          ClientProperties properties = info.getProperties();
          propertiesBean.merge(properties);
        }
        else
        {
          warnNotUsingWebClientInfo(clientInfo);
View Full Code Here

      // if we get here, the redirect already has been done; clear
      // the meta data entry; we don't need it any longer is the client
      // info object will be cached too
      session.setMetaData(BROWSER_WAS_POLLED_KEY, (Boolean)null);
    }
    return new WebClientInfo(this);
  }
View Full Code Here

    RequestCycle requestCycle = getRequestCycle();
    WebSession session = (WebSession)getSession();
    ClientInfo clientInfo = session.getClientInfo();
    if (clientInfo == null)
    {
      clientInfo = new WebClientInfo(requestCycle);
      getSession().setClientInfo(clientInfo);
    }
    else if (clientInfo instanceof WebClientInfo)
    {
      WebClientInfo info = (WebClientInfo)clientInfo;
      ClientProperties properties = info.getProperties();
      properties.setJavaEnabled(false);
    }
    else
    {
      warnNotUsingWebClientInfo(clientInfo);
View Full Code Here

TOP

Related Classes of org.apache.wicket.protocol.http.request.WebClientInfo

Copyright © 2018 www.massapicom. 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.