title: problems with flags intent
body: <p>On my code I have 2 apps.
  the app a that starts app b, like a launcher.</p>
  
  <p>the code app a looks like that:</p>
  
  <pre><code>    Intent i = new Intent(Intent.ACTION_MAIN);
      PackageManager manager = getPackageManager();
      i = manager.getLaunchIntentForPackage("com.test.vayo");
      i.addCategory(Intent.CATEGORY_LAUNCHER);
      startActivity(i);
      finish();
  </code></pre>
  
  <p>the code on app B:</p>
  
  <pre><code>            Intent intent = new Intent(this.context, first.class);
              intent.setFlags(intent.FLAG_ACTIVITY_REORDER_TO_FRONT);
              context.startActivity(intent);
              finish();
  </code></pre>
  
  <p>my problem that to start task b only if a didnt start the app b.For that I am trying to bring to front the task that already running and not to start all activities from the root one, just to bring to front back stack of the privous task.
  for that I am using FLAG_ACTIVITY_REORDER_TO_FRONT its works only if I run first app b and the app a, but if I run a and then run b it isnt working,its starts b from the root activity.</p>