Package org.apache.wicket.protocol.http

Examples of org.apache.wicket.protocol.http.ClientProperties


        }

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


        }

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

      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

    // properties by redirecting to a special page.

    // don't use a property model here or anything else that is resolved
    // during rendering, as changing the request target during rendering
    // is not allowed.
    final ClientProperties properties = ((WebClientInfo)getRequestCycle().getClientInfo()).getProperties();

    add(new MultiLineLabel("clientinfo", properties.toString()));

    IModel<String> clientTimeModel = new AbstractReadOnlyModel<String>()
    {
      /**
       * @see org.apache.wicket.model.AbstractReadOnlyModel#getObject()
       */
      @Override
      public String getObject()
      {
        TimeZone timeZone = properties.getTimeZone();
        if (timeZone != null)
        {
          Calendar cal = Calendar.getInstance(timeZone);
          Locale locale = getLocale();
          DateFormat dateFormat = DateFormat.getTimeInstance(DateFormat.LONG, locale);
View Full Code Here

        }

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

      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

      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

    // properties by redirecting to a special page.

    // don't use a property model here or anything else that is resolved
    // during rendering, as changing the request target during rendering
    // is not allowed.
    final ClientProperties properties = ((WebClientInfo)Session.get().getClientInfo()).getProperties();

    add(new MultiLineLabel("clientinfo", properties.toString()));

    IModel<String> clientTimeModel = new AbstractReadOnlyModel<String>()
    {
      /**
       * @see org.apache.wicket.model.AbstractReadOnlyModel#getObject()
       */
      @Override
      public String getObject()
      {
        TimeZone timeZone = properties.getTimeZone();
        if (timeZone != null)
        {
          Calendar cal = Calendar.getInstance(timeZone);
          Locale locale = getLocale();
          DateFormat dateFormat = DateFormat.getTimeInstance(DateFormat.LONG, locale);
View Full Code Here

    final MultiLineLabel clientInfo = new MultiLineLabel("clientinfo", new AbstractReadOnlyModel<String>()
    {
      @Override
      public String getObject()
      {
        ClientProperties properties = getClientProperties();
        return properties.toString();
      }
    });
    clientInfo.setOutputMarkupPlaceholderTag(true);
    clientInfo.setVisible(false);

    IModel<String> clientTimeModel = new AbstractReadOnlyModel<String>()
    {
      @Override
      public String getObject()
      {
        ClientProperties properties = getClientProperties();
        TimeZone timeZone = properties.getTimeZone();
        if (timeZone != null)
        {
          Calendar cal = Calendar.getInstance(timeZone);
          Locale locale = getLocale();
          DateFormat dateFormat = DateFormat.getTimeInstance(DateFormat.LONG, locale);
View Full Code Here

   */
  private ClientProperties getClientProperties()
  {
    IRequestCycleSettings requestCycleSettings = getApplication().getRequestCycleSettings();
    boolean gatherExtendedBrowserInfo = requestCycleSettings.getGatherExtendedBrowserInfo();
    ClientProperties properties = null;
    try
    {
      requestCycleSettings.setGatherExtendedBrowserInfo(false);
      WebClientInfo clientInfo = (WebClientInfo) getSession().getClientInfo();
      properties = clientInfo.getProperties();
View Full Code Here

TOP

Related Classes of org.apache.wicket.protocol.http.ClientProperties

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.