Gelmiş geçmiş en büyük porno sitemiz olan 2pe de her zaman en kaliteli pornoları sunmayı hedefledik. Diğer video sitemiz olan vuam da ise hd porno ağırlıklı çalışmalara başladık.

  1. #1
    Touch Premium Member pkellner's Avatar
    Join Date
    Sep 2008
    Location
    San Jose, California
    Posts
    750
    Vote Rating
    24
    pkellner will become famous soon enough pkellner will become famous soon enough

      0  

    Default In a panel class, how to run a function after contructor creation

    In a panel class, how to run a function after contructor creation


    I've got a simple panel in architect that has a normal function in it. I want to execute that function after the construction of the panel completes. I did it successfully with the "override" but that seems like overkill. Is there some way to do that directly in SA without creating an override.

    this is what I did that works but hoping for a simpler solution.

    Code:
    Ext.define('RegistrationApp.view.override.TabWizardPanel', {
        override: 'RegistrationApp.view.TabWizardPanel',
        
         constructor: function () {
            this.callParent(arguments);
            this.hideTabTitles();
        }
        
    });

    Though for my example the generated class is not really necessary to show, but here it is just to add some context to this question.

    Code:
    Ext.define('RegistrationApp.view.TabWizardPanel', {
        extend: 'Ext.tab.Panel',
        alias: 'widget.tabWizardPanelAlias',
    
    
        requires: [
            'RegistrationApp.view.AttendeeSpeakerOrSponsor',
            'RegistrationApp.view.AttendeeOrSpeaker',
            'RegistrationApp.view.ForgotUsernameOrPassword',
            'RegistrationApp.view.sponsor',
            'RegistrationApp.view.override.TabWizardPanel'
        ],
    
    
        height: 450,
        id: 'TabWizardId',
        itemId: '',
        activeTab: 0,
    
    
        initComponent: function() {
            var me = this;
    
    
            Ext.applyIf(me, {
                items: [
                    {
                        xtype: 'AttendeeSpeakerOrSponsorAlias',
                        id: 'AttendeeSpeakerSponsorId'
                    },
                    {
                        xtype: 'AttendeeOrSpeakerAlias'
                    },
                    {
                        xtype: 'ForgotUsernameAlias'
                    },
                    {
                        xtype: 'sponsorAlias'
                    }
                ]
            });
    
    
            me.callParent(arguments);
        },
    
    
        getTabIdByName: function(stepName) {
    
    
            var tabId = -1;
            if (stepName === 'AttendeeSpeakerSponsorId') {
                tabId = 0;
            } else if (stepName === 'attendeeorspeaker') {
                tabId = 1;
            } else if (stepName === 'forgotusernameorpassword') {
                tabId = 2;
            } else if (stepName === 'Sponsor') {
                tabId = 3;
            }
            return tabId;
    
    
        },
    
    
        hideTabTitles: function() {
            console.log('hideTabTitles');
            this.getTabBar().hide();
            this.componentLayout.childrenChanged = true;
            this.doComponentLayout();
        }
    
    
    });
    Last edited by pkellner; 9 Feb 2013 at 10:56 AM. Reason: added generated class for completeness