Add quick toggle shortcut (#950)

Mainly for Android 7.1, also backward compatible.
This commit is contained in:
Mygod
2016-10-23 14:16:56 +08:00
parent 54c696d00a
commit 244c2ecdfd
3 changed files with 65 additions and 0 deletions
+13
View File
@@ -53,6 +53,8 @@
<intent-filter>
<action android:name="android.service.quicksettings.action.QS_TILE" />
</intent-filter>
<meta-data android:name="android.app.shortcuts"
android:resource="@xml/shortcuts"/>
</activity>
<activity
@@ -116,6 +118,17 @@
</intent-filter>
</activity>
<activity
android:name=".QuickToggleShortcut"
android:label="@string/quick_toggle"
android:theme="@android:style/Theme.NoDisplay"
android:excludeFromRecents="true"
android:launchMode="singleTask">
<intent-filter>
<action android:name="android.intent.action.CREATE_SHORTCUT" />
</intent-filter>
</activity>
<service
android:name=".ShadowsocksRunnerService"
android:exported="false">