Results 1 to 3 of 3

Thread: How to set Animation to 'from left to right' when click myback button?

  1. #1

    Default Answered: How to set Animation to 'from left to right' when click myback button?

    Below codes not work, thank you for your help!

    Code:
    		onBack: function(){
    			ASVari.PAGE_CHANGE_FROM_BACK = true;
    			
    			var item = ASVari.ACTION_MAP.pop();
    			item.setShowAnimation({ type: "slide", direction: "left" });
    			Ext.getCmp('MainView').getActiveItem().setActiveItem(item);
    			console.log('back to '+ item.id);		
    		},

  2. Looks like you are using a card layout? If so then you need to use the animation on the layout...

    Code:
    container.getLayout().getAnimation().setReversed(true);

  3. #2
    Sencha Premium User mitchellsimoens's Avatar
    Join Date
    Mar 2007
    Location
    Gainesville, FL
    Posts
    40,451
    Answers
    3997

    Default

    Looks like you are using a card layout? If so then you need to use the animation on the layout...

    Code:
    container.getLayout().getAnimation().setReversed(true);
    Mitchell Simoens @LikelyMitch
    Modus Create, Senior Fullstack Engineer
    ________________
    Modus Create is based on the model of an open source team. We’re a remote, global team of experts in our field. To find out more about the work we do, head over to our website.

    Check out my GitHub:
    https://github.com/mitchellsimoens

  4. #3

    Default It works well, thank you a lot!

    It works well, thank you a lot!
    Code:
    			currentView.getLayout().getAnimation().setReverse(true)			currentView.setActiveItem(item);
    			currentView.getLayout().getAnimation().setReverse(false)

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •