1. #1
    Ext GWT Premium Member
    Join Date
    Aug 2010
    Location
    Germany, Solingen
    Posts
    239
    Answers
    4
    Vote Rating
    2
    gishmo is on a distinguished road

      0  

    Default Answered: change occapacity of disabled field

    Answered: change occapacity of disabled field


    What is the best way to change the occapacity of disable fields for the whole application in GXT 3?

  2. We have modified CommonStyles to be Appearance based. With these changes, you can substitute your own implementation with your custom styles. You would define your own rule similar to this:

    Code:
    <replace-with class="com.sencha.gxt.core.client.resources.CommonStyles.CommonStylesDefaultAppearance">
      <when-type-is class="com.sencha.gxt.core.client.resources.CommonStyles.CommonStylesAppearance" />
    </replace-with>
    Changes are in SVN.

  3. #2
    Sencha - GXT Dev Team darrellmeyer's Avatar
    Join Date
    May 2007
    Location
    Washington, DC
    Posts
    2,242
    Answers
    1
    Vote Rating
    2
    darrellmeyer is on a distinguished road

      0  

    Default


    We have modified CommonStyles to be Appearance based. With these changes, you can substitute your own implementation with your custom styles. You would define your own rule similar to this:

    Code:
    <replace-with class="com.sencha.gxt.core.client.resources.CommonStyles.CommonStylesDefaultAppearance">
      <when-type-is class="com.sencha.gxt.core.client.resources.CommonStyles.CommonStylesAppearance" />
    </replace-with>
    Changes are in SVN.

  4. #3
    Sencha User
    Join Date
    Sep 2012
    Posts
    31
    Answers
    2
    Vote Rating
    1
    billsalvucci is on a distinguished road

      0  

    Default


    You didn't give CommonStylesDefaultAppearance a constructor that takes a ClientBundle and you made the bundle and style properties private

    Code:
    private final CommonDefaultResources bundle;
        private final Styles styles;
        
        public CommonStylesDefaultAppearance() {
          bundle = GWT.create(CommonDefaultResources.class);
          styles = bundle.styles();
        }
    Normally, I would extend the default appearance using a default constructor that calls super with my ClientBundle

    Code:
    public interface Resources extends CommonDefaultResources {
    
              ImageResource shim();
    
              @Override
              @Source("CommonStyles.css")
              Styles styles();
    
            }
    
            public interface Styles extends CommonDefaultStyles {
    
            }
            
            public MyStylesAppearance() {
                super(GWT.<Resources> create(Resources.class));
            }
    and I can't work around by doing

    Code:
    public MyStylesAppearance() {
                bundle = GWT.create(CommonDefaultResources.class);
                styles = bundle.styles();
              }
    because bundle and styles are private.

  5. #4
    Sencha - GXT Dev Team
    Join Date
    Feb 2009
    Location
    Minnesota
    Posts
    2,731
    Answers
    109
    Vote Rating
    90
    Colin Alworth is a glorious beacon of light Colin Alworth is a glorious beacon of light Colin Alworth is a glorious beacon of light Colin Alworth is a glorious beacon of light Colin Alworth is a glorious beacon of light

      0  

    Default


    While that is true, the CommonStylesAppearance interface is simple enough that you shouldn't be extending the default implementation - just implement your own, perhaps extending the ClientBundle or declaring your own. Then declare that in your module as the replacement for CommonStylesAppearance, as Darrell indicated in his post.

    In cases where there is an abstract base appearance, there is some logic being provided that often would be shared by most real implementations of that appearance. There is no such logic here, so using the base class gains you nothing.

  6. #5
    Sencha User
    Join Date
    Oct 2013
    Posts
    13
    Vote Rating
    0
    ekschperte is on a distinguished road

      0  

    Default


    Could please somebody help me again with that problem?

    My following code is not working. The CommonStyles are not overriden.

    Code:
    import com.google.gwt.core.client.GWT;
    import com.google.gwt.resources.client.ClientBundle;
    import com.sencha.gxt.core.client.resources.CommonStyles.CommonStylesDefaultAppearance;
    
    
    public class DABCommonStylesAppearance extends CommonStylesDefaultAppearance{
      
      public interface DABCommonStylesResources extends ClientBundle, CommonDefaultResources {
        
        @Source({"com/sencha/gxt/core/client/resources/CommonStyles.css","DABCommonStyles.css"})
        @Override
        MyCommonStylesStyle styles();
      }
      
      public interface MyCommonStylesStyle extends CommonDefaultStyles {
      }
      
      public DABCommonStylesAppearance() {
        this(GWT.<DABCommonStylesResources> create(DABCommonStylesResources.class));
      }
    
    
      public DABCommonStylesAppearance(DABCommonStylesResources resources) {
        super();
      }
    
    
    }
    I copied all contents of CommonStyles.css to DABCommonStyles.css. In detail, I would like to adapt the ".disabled"-CSS class. But the result is only the default ".disabled" style...

    Also I set
    <replace-with class="com.elaxy.theme.dab.client.resources.DABCommonStylesAppearance">
    <when-type-is class="com.sencha.gxt.core.client.resources.CommonStyles.CommonStylesAppearance" />
    </replace-with>
    in my GWT.xml

    Regards, Steven

  7. #6
    Sencha User
    Join Date
    Oct 2013
    Posts
    13
    Vote Rating
    0
    ekschperte is on a distinguished road

      0  

    Default


    I finally managed it...
    Here is my code.

    Code:
    package com.elaxy.theme.dab.client.resources;
    
    
    import com.google.gwt.core.client.GWT;
    import com.google.gwt.resources.client.ClientBundle;
    import com.google.gwt.resources.client.ImageResource;
    import com.sencha.gxt.core.client.resources.StyleInjectorHelper;
    import com.sencha.gxt.core.client.resources.CommonStyles.CommonStylesDefaultAppearance;
    
    
    public class DABCommonStylesAppearance extends CommonStylesDefaultAppearance{
      
      static interface DABCommonStylesResources extends ClientBundle{
        
        @Source({"DABCommonStyles.css"})
        MyCommonStyle styles();
        ImageResource shim();
      }
      
      private DABCommonStylesResources bundle;
      private CommonDefaultStyles style;
      
      @Override
      public CommonDefaultStyles styles(){
        return style;
      }
      
      public interface MyCommonStyle extends CommonDefaultStyles {
        
      }
      
      public DABCommonStylesAppearance() {
    
    
        this.bundle = GWT.create(DABCommonStylesResources.class);
        this.style = bundle.styles();
        StyleInjectorHelper.ensureInjected(this.style, true);
      }
    
    
    }

Turkiyenin en sevilen filmlerinin yer aldigi xnxx internet sitemiz olan ve porn sex tarzi bir site olan mobil porno izle sitemiz gercekten dillere destan bir durumda herkesin sevdigi bir site olarak tarihe gececege benziyor. Sitenin en belirgin ozelliklerinden birisi de Turkiyede gercekten kaliteli ve muntazam, duzenli porno izle siteleri olmamasidir. Bu yuzden iste. Ayrica en net goruntu kalitesine sahip adresinde yayinlanmaktadir. Mesela diğer sitelerimizden bahsedecek olursak, en iyi hd porno video arşivine sahip bir siteyiz. "The Best anal porn videos and slut anus, big asses movies set..." hd porno faketaxi