title: LayoutTransition custom the transition
body: <p>I try to set a custom animation between 2 layouts.</p>
  
  <pre><code>public class MainActivity extends FragmentActivity {
  
      View menu = null;
      ViewGroup parent = null;
  
      @Override
      protected void onCreate(Bundle savedInstanceState) {
          super.onCreate(savedInstanceState);
          setContentView(R.layout.fragment_models);
  
          //initialize the container and his parent
          menu = findViewById(R.id.menu_model);
          parent = (ViewGroup) menu.getParent();
  
          //set transition
          LayoutTransition lt = new LayoutTransition();
          lt.enableTransitionType(LayoutTransition.CHANGING);
          parent.setLayoutTransition(lt);
  
          restoreMenu(null);
      }
  
      //display second menu
      public void changeMenu(View view) {
  
          int index = parent.indexOfChild(menu);
          View old = menu;
          menu = getLayoutInflater().inflate(R.layout.menu_2, parent, false);
          parent.addView(menu, index);
          parent.removeView(old);
      }
  
      //display first menu
      public void restoreMenu(View view) {
  
          int index = parent.indexOfChild(menu);
          View old = menu;
          menu = getLayoutInflater().inflate(R.layout.menu_1, parent, false);
          parent.addView(menu, index);
          parent.removeView(old);
      }
  }
  </code></pre>
  
  <p>As you can see I'm using <code>LayoutTransition</code> with the <code>LayoutTransition.CHANGING</code> effect.
  But I want it looks like this:</p>
  
  <p>My old menu is leaving to the left and my new menu is coming from the right.</p>
  
  <p>Do you have any ideas how I could do that ? Does the <code>LayoutTransition</code> can do that ?</p>