title: cannot start activity background in android 10 [ android Q ]
body: <p>I use android 10 [android Q, galaxy 10],</p>
  
  <p>I use android studio 3.3,</p>
  
  <p>using AVD, and made a api 29 [android 10] virtual phone.</p>
  
  <p>at the virtual machine,
  I execute my app , after that, I launch other app like calendar, calculator.
  so my app activity get into background mode.</p>
  
  <p>when I receive a message at BroadcastReceiver. 
  I call startActivity.</p>
  
  <p>here, code -->
  public class myReceiver extends BroadcastReceiver {}</p>
  
  <pre><code>public void onReceive(Context context, Intent intent)
  {
          Intent intentRun = new Intent(context, LoginSuccess.class);
          intentRun.addFlags(Intent.FLAG_ACTIVITY_NEW_TASK|Intent.FLAG_ACTIVITY_CLEAR_TASK);
          context.startActivity(intentRun);
  }
  </code></pre>
  
  <p>but LoginSuccess activity  do not shows up.
  [when my app is in background mode]</p>
  
  <p>using same code, LoginSuccess activity show up very well
  when my app is in foreground mode.</p>
  
  <p><a href="https://i.stack.imgur.com/tPJeD.png" rel="noreferrer">call stack capture image</a></p>
  
  <p>above image shows call stack 
  right before I call startActivity in broadcast receiver.</p>
  
  <p>I have read guide line for android 10 background activity issue.
  [developer.android.com/~~ some location]</p>
  
  <p>at the guide line,</p>
  
  <p>I came to know that 
  if the activity exists in call stack, it can be started 
  even in background mode.</p>
  
  <p>above code, 
  it try to start activity that exists in recent call stack.</p>
  
  <p>why startActivity call fail in background mode ? 
  [maybe not fail , but anyway not activated into foreground]</p>