1. #1
    Sencha User
    Join Date
    Sep 2008
    Posts
    232
    Vote Rating
    0
    sz_146 is on a distinguished road

      0  

    Default Different style tree nodes/items ?

    Different style tree nodes/items ?


    Is it possible to have differently styled tree items/nodes, using GXT 2 M3 ? Depending on a model's property I would like to give it a different style in the TreePanel.

  2. #2
    Ext User fother's Avatar
    Join Date
    Sep 2007
    Location
    Brazil
    Posts
    744
    Vote Rating
    -1
    fother is an unknown quantity at this point

      0  

    Default


    update the css

  3. #3
    Sencha User
    Join Date
    Sep 2008
    Posts
    232
    Vote Rating
    0
    sz_146 is on a distinguished road

      0  

    Default Different style tree nodes/items

    Different style tree nodes/items


    How can you do it for different nodes/items in the same tree ?

  4. #4
    Ext User
    Join Date
    Mar 2008
    Location
    Berlin, Germany
    Posts
    58
    Vote Rating
    0
    HerrB is on a distinguished road

      0  

    Default


    See AsyncTreePanelExample using a ModelIconProvider, e.g.:

    Code:
    tree.setIconProvider(new ModelIconProvider<FileModel>() {
    
          public AbstractImagePrototype getIcon(FileModel model) {
            if (!(model instanceof FolderModel)) {
              String ext = model.getName().substring(model.getName().lastIndexOf(".") + 1);
    
              // new feature, using image paths rather than style names
              if ("xml".equals(ext)) {
                return IconHelper.createPath("samples/images/icons/page_white_code.png");
              } else if ("java".equals(ext)) {
                return IconHelper.createPath("samples/images/icons/page_white_cup.png");
              } else if ("html".equals(ext)) {
                return IconHelper.createPath("samples/images/icons/html.png");
              } else {
                return IconHelper.createPath("samples/images/icons/page_white.png");
              }
            }
            return null;
          }
        });
    Regards,

    HerrB

  5. #5
    Sencha User
    Join Date
    Sep 2008
    Posts
    232
    Vote Rating
    0
    sz_146 is on a distinguished road

      0  

    Default Different style tree nodes/items

    Different style tree nodes/items


    I guess this only allows you to change the icons on the nodes. I need to have some of the tree nodes appear blurred/grayed out.

  6. #6
    Ext User dpope22's Avatar
    Join Date
    Apr 2008
    Location
    San Antonio, TX
    Posts
    35
    Vote Rating
    0
    dpope22 is on a distinguished road

      0  

    Default


    I have the same issue. I have the need for some of the items in the tree to have highlighting using css. Previously, this was done by applying the css to the individual TreeItems. Is there a way to do this with the new TreePanel?
    Rackspace Software Developer

Thread Participants: 3

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