title: No response from intent to prompt user to set default handler for SMS
body: <p>I'm currently having trouble getting the app to send the user a dialogue to set the default handler for SMS on API 29. </p>
  
  <p>I initially followed <a href="https://developer.android.com/guide/topics/permissions/default-handlers" rel="nofollow noreferrer">https://developer.android.com/guide/topics/permissions/default-handlers</a>. </p>
  
  <p>It didn't work so I looked around and saw this: <a href="https://stackoverflow.com/questions/21212690/how-to-set-default-sms-prompt-for-kitkat">How to set Default SMS prompt for KitKat</a>. </p>
  
  <p>So I followed <a href="https://android-developers.googleblog.com/2013/10/getting-your-sms-apps-ready-for-kitkat.html" rel="nofollow noreferrer">https://android-developers.googleblog.com/2013/10/getting-your-sms-apps-ready-for-kitkat.html</a> and added the snippet to my manifest XML (without actual implementation, as the StackOverflow user said in the post). Unfortunately every time I click the button that starts the <code>ACTION_CHANGE_DEFAULT</code> intent, nothing happens except he log. </p>
  
  <p>My main activity has the following onCreate:</p>
  
  <pre><code>    override fun onCreate(savedInstanceState: Bundle?) {
          super.onCreate(savedInstanceState)
          setContentView(R.layout.activity_main)
          var btn = findViewById&lt;Button&gt;(R.id.button3)
          btn.setOnClickListener {
              Log.d("TAG", "Sending change default intent")
              val setSmsAppIntent = Intent(Telephony.Sms.Intents.ACTION_CHANGE_DEFAULT)
              setSmsAppIntent.putExtra(Telephony.Sms.Intents.EXTRA_PACKAGE_NAME, packageName)
              startActivityForResult(setSmsAppIntent, CHANGE_SMS_DEFAULT_RESULT)
          }
      }
  </code></pre>
  
  <p>Manifest:</p>
  
  <pre class="lang-xml prettyprint-override"><code>&lt;?xml version="1.0" encoding="utf-8"?&gt;
  &lt;manifest xmlns:android="http://schemas.android.com/apk/res/android"
      package="com.example.testapplication"&gt;
  
      &lt;uses-permission android:name="android.permission.READ_SMS" /&gt;
  
      &lt;application
          android:allowBackup="true"
          android:icon="@mipmap/ic_launcher"
          android:label="@string/app_name"
          android:roundIcon="@mipmap/ic_launcher_round"
          android:supportsRtl="true"
          android:theme="@style/AppTheme"&gt;
          &lt;service
              android:name=".FetchSMS"
              android:exported="false"&gt;&lt;/service&gt;
  
          &lt;activity
              android:name=".DisplayMessageActivity"
              android:parentActivityName=".MainActivity" /&gt;
          &lt;activity android:name=".MainActivity"&gt;
              &lt;intent-filter&gt;
                  &lt;action android:name="android.intent.action.MAIN" /&gt;
  
                  &lt;category android:name="android.intent.category.LAUNCHER" /&gt;
              &lt;/intent-filter&gt;
          &lt;/activity&gt;
  
          &lt;!-- These are ONLY used to set app as default SMS --&gt;
          &lt;receiver android:name=".SmsReceiver"
              android:permission="android.permission.BROADCAST_SMS"&gt;
              &lt;intent-filter&gt;
                  &lt;action android:name="android.provider.Telephony.SMS_DELIVER" /&gt;
              &lt;/intent-filter&gt;
          &lt;/receiver&gt;
  
          &lt;!-- BroadcastReceiver that listens for incoming MMS messages --&gt;
          &lt;receiver android:name=".MmsReceiver"
              android:permission="android.permission.BROADCAST_WAP_PUSH"&gt;
              &lt;intent-filter&gt;
                  &lt;action android:name="android.provider.Telephony.WAP_PUSH_DELIVER" /&gt;
                  &lt;data android:mimeType="application/vnd.wap.mms-message" /&gt;
              &lt;/intent-filter&gt;
          &lt;/receiver&gt;
  
          &lt;!-- Activity that allows the user to send new SMS/MMS messages --&gt;
          &lt;activity android:name=".ComposeSmsActivity" &gt;
              &lt;intent-filter&gt;
                  &lt;action android:name="android.intent.action.SEND" /&gt;
                  &lt;action android:name="android.intent.action.SENDTO" /&gt;
                  &lt;category android:name="android.intent.category.DEFAULT" /&gt;
                  &lt;category android:name="android.intent.category.BROWSABLE" /&gt;
                  &lt;data android:scheme="sms" /&gt;
                  &lt;data android:scheme="smsto" /&gt;
                  &lt;data android:scheme="mms" /&gt;
                  &lt;data android:scheme="mmsto" /&gt;
              &lt;/intent-filter&gt;
          &lt;/activity&gt;
  
          &lt;!-- Service that delivers messages from the phone "quick response" --&gt;
          &lt;service android:name=".HeadlessSmsSendService"
              android:permission="android.permission.SEND_RESPOND_VIA_MESSAGE"
              android:exported="true" &gt;
              &lt;intent-filter&gt;
                  &lt;action android:name="android.intent.action.RESPOND_VIA_MESSAGE" /&gt;
                  &lt;category android:name="android.intent.category.DEFAULT" /&gt;
                  &lt;data android:scheme="sms" /&gt;
                  &lt;data android:scheme="smsto" /&gt;
                  &lt;data android:scheme="mms" /&gt;
                  &lt;data android:scheme="mmsto" /&gt;
              &lt;/intent-filter&gt;
          &lt;/service&gt;
  
      &lt;/application&gt;
  
  &lt;/manifest&gt;
  </code></pre>
  
  <p>Log:</p>
  
  <p><a href="https://i.stack.imgur.com/k18Xm.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/k18Xm.png" alt="enter image description here"></a></p>
  
  <p>Would appreciate some help. Thanks in advance.</p>
  
  <p>My <code>minSdkVersion</code> is 19</p>
  
  <p>Edit: I just tried this on the emulator on KitKat (API 19) and it worked - but it doesn't on Q (API 29)</p>