nl_tokens: Adds a filter to the collection and observes it for state change .
pl_tokens: function ( config ) { var me = this , columns = me . getGridPanel ( ) . columns , i , columnsLength , column , filtersLength , filter ; for ( i = 0 , columnsLength = columns . length ; i < columnsLength ; i ++ ) { column = columns [ i ] ; if ( column . dataIndex === config . dataIndex ) { column . filter = config ; } } if ( me . view . headerCt . menu ) { me . createFilters ( ) ; } else { // Call getMenu() to ensure the menu is created, and so, also are the filters. We cannot call // createFilters() withouth having a menu because it will cause in a recursion to applyState() // that ends up to clear all the filter values. This is likely to happen when we reorder a column // and then add a new filter before the menu is recreated. me . view . headerCt . getMenu ( ) ; } for ( i = 0 , filtersLength = me . filters . <mask> . length ; i < filtersLength ; i ++ ) { filter = me . filters . items [ i ] ; if ( filter . dataIndex === config . dataIndex ) { return filter ; } } }