Skip to content

Commit

Permalink
Implement Muzei API
Browse files Browse the repository at this point in the history
  • Loading branch information
jahirfiquitiva committed Jun 7, 2020
1 parent fbd6bde commit d6dd55f
Show file tree
Hide file tree
Showing 4 changed files with 41 additions and 1 deletion.
21 changes: 20 additions & 1 deletion app/src/main/AndroidManifest.xml
Original file line number Diff line number Diff line change
Expand Up @@ -72,14 +72,33 @@
android:resource="@xml/file_providers" />
</provider>

<!-- Muzei Service -->
<provider
android:name=".MuzeiService"
android:authorities="${applicationId}.muzei"
android:exported="true"
android:icon="@drawable/ic_muzei_icon"
android:label="@string/app_name"
android:permission="com.google.android.apps.muzei.api.ACCESS_PROVIDER">
<intent-filter>
<action android:name="com.google.android.apps.muzei.api.MuzeiArtProvider" />
</intent-filter>

<meta-data
android:name="color"
android:value="@color/accent" />
<meta-data
android:name="settingsActivity"
android:value="dev.jahir.kuper.ui.activities.KuperMuzeiSettingsActivity" />
</provider>

<!-- TODO: Remove comment marks to enable Zooper
<provider
android:name=".ZooperProvider"
android:authorities="${applicationId}.zwprovider"
tools:ignore="ExportedContentProvider"/>
-->


<!-- TODO: Remove comment marks to enable Kustom Skins
* Remove intent-filter action lines according to your needs.
* If you're not going to provide one of the options, remove its respective line.
Expand Down
5 changes: 5 additions & 0 deletions app/src/main/kotlin/dev/jahir/kuper/app/MuzeiService.kt
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
package dev.jahir.kuper.app

import dev.jahir.frames.muzei.FramesArtProvider

class MuzeiService : FramesArtProvider()
9 changes: 9 additions & 0 deletions library/src/main/AndroidManifest.xml
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,11 @@
android:name="dev.jahir.frames.ui.activities.SettingsActivity"
android:exported="false" />

<activity
android:name="dev.jahir.frames.ui.activities.MuzeiSettingsActivity"
android:exported="false"
tools:replace="android:exported" />

<activity
android:name=".ui.activities.KuperViewerActivity"
android:exported="false" />
Expand All @@ -28,6 +33,10 @@
</intent-filter>
</activity>

<activity
android:name=".ui.activities.KuperMuzeiSettingsActivity"
android:exported="true" />

</application>

</manifest>
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
package dev.jahir.kuper.ui.activities

import dev.jahir.frames.ui.activities.MuzeiSettingsActivity

class KuperMuzeiSettingsActivity : MuzeiSettingsActivity() {
override fun shouldShowCollections(): Boolean = false
}

0 comments on commit d6dd55f

Please sign in to comment.