1. #1
    Sencha User
    Join Date
    Aug 2009
    Posts
    480
    Vote Rating
    1
    plalx has a spectacular aura about plalx has a spectacular aura about

      0  

    Default Ext.Component.findParentByType (supporting inheritance seach)

    Ext.Component.findParentByType (supporting inheritance seach)


    The current findParentByType method doesn't support inheritance search.
    There are many cases where it is usefull to be able to find a parent by its parent class.
    Here's a replacement for the native Ext.Component.findParentByType method.
    This method is supporting inheritance search for class names and xtypes.

    Code:
    Ext.override(Ext.Component, {
     findParentByType: function(type){
      if (Ext.isFunction(type)){
       return this.findParentBy(function(p){
                    return p instanceof type;
                });
      } else {
       return (Ext.isFunction(Ext.ComponentMgr.types[type]))? 
        this.findParentByType(Ext.ComponentMgr.types[type]): 
        null;
      }
     }
    });
    Last edited by mystix; 1 Apr 2010 at 7:32 AM. Reason: POST CODE IN [code][/code] TAGS. see http://extjs.com/forum/misc.php?do=bbcode#code

  2. #2
    Sencha User
    Join Date
    Nov 2008
    Posts
    17
    Vote Rating
    0
    superbinary is on a distinguished road

      0  

    Default thanks!

    thanks!


    it's really useful. thanks!

Thread Participants: 1

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