android - How to add a notification settings activity to the system settings -


on android 5.0 there option through settings -> sound & notification -> app notification -> calendar (for example) go directly notification settings of app.
know it's flag in manifest described in dev.bytes talk.
how can achieved, flag used?

here screenshot more clarification:
enter image description here

you need add intent category notification.intent_category_notification_preferences activity you'd launch through androidmanifest. simple example like:

    <activity android:name="com.example.packagename.yoursettingsactivity" >          <intent-filter>             <action android:name="android.intent.action.main" />             <category android:name="android.intent.category.notification_preferences" />         </intent-filter>     </activity> 

for more information, refer settings app , notificationapplist , appnotificationsettings fragments.

results

example


Comments

Popular posts from this blog

resizing Telegram inline keyboard -

command line - How can a Python program background itself? -

php - "cURL error 28: Resolving timed out" on Wordpress on Azure App Service on Linux -