1. #1
    Sencha Premium Member
    Join Date
    Jan 2012
    Location
    Lahore
    Posts
    53
    Vote Rating
    -1
    waqar is an unknown quantity at this point

      0  

    Default Unanswered: Keeping Same Icons for Expanded / collapsed Nodes of Tree Gird.

    Unanswered: Keeping Same Icons for Expanded / collapsed Nodes of Tree Gird.


    I am working with Tree, I set IconCls string value from server based on the node value and send json to browser, tree icons displays perfect but when node is clicked the icon turn into a UGLY open Folder icon for no reason, how can I over ride this so that it do not change to folder icon , I want to keep the same Icon class which I sent in IconCls to be visible not this folder Icon Class, this is my tree :

    Code:
    Ext.define('Application.MyGridTree', {
            extend: 'Ext.tree.Panel',
            // Settings
           useArrows: true,
            rootVisible: false,
            store: clientTreeStore,
            multiSelect: false,
            singleExpand: true,
            allowDeselect :true,
    initComponent : function() {
    this.callParent();
    }


    This is the Model:
    Code:
    Ext.define('clientsTree', {
    extend: 'Ext.data.Model', fields : [ {name : 'userId'}, {name : 'userName'},
    {name : 'iconCls'},
    {name : 'expanded'}, {name : 'leaf'}, ], idProperty: 'userId' });


    This is store:
    Code:
    var clientTreeStore = Ext.create('Ext.data.TreeStore', {
            model: 'userTree',
            proxy: {
                type: 'ajax',
                url : 'treeService'
            },
            folderSort: true
        });
    Last edited by waqar; 6 Apr 2012 at 5:00 AM. Reason: Improving messege

  2. #2
    Sencha Premium Member
    Join Date
    Jan 2012
    Location
    Lahore
    Posts
    53
    Vote Rating
    -1
    waqar is an unknown quantity at this point

      0  

    Default overriding Default CSS works - But no in my situation

    overriding Default CSS works - But no in my situation


    I did find out that if I copy this to my css it overrides the defualt 'UGLY' folder icon but this bounds me to stick to the icon which is hard coded in this CSS:
    Code:
    .x-grid-tree-node-expanded .x-tree-icon-parent {
        background-image:url("./ext/resources/images/default/s.gif");
        padding-top: 1px;
    }
    What I need is to stay with the icon passed from server ie. in "iconCls" attribute.

    any help would be appricaited!!!

    Cheers!

film izle

hd film izle

film sitesi

takipci kazanma sitesi

takipci kazanma sitesi

güzel olan herşey

takipci alma sitesi

komik eğlenceli videolar