Implement backup and restore for new theme types
This commit is contained in:
@@ -2,6 +2,7 @@ plugins {
|
||||
alias(libs.plugins.android.library)
|
||||
alias(libs.plugins.kotlin.android)
|
||||
alias(libs.plugins.ksp)
|
||||
alias(libs.plugins.kotlin.plugin.serialization)
|
||||
}
|
||||
|
||||
android {
|
||||
@@ -54,5 +55,6 @@ dependencies {
|
||||
implementation(project(":core:i18n"))
|
||||
implementation(project(":core:ktx"))
|
||||
implementation(project(":core:preferences"))
|
||||
implementation(project(":core:base"))
|
||||
|
||||
}
|
||||
@@ -2,11 +2,15 @@ package de.mm20.launcher2.database.entities
|
||||
|
||||
import androidx.room.Entity
|
||||
import androidx.room.PrimaryKey
|
||||
import de.mm20.launcher2.serialization.UUIDSerializer
|
||||
import kotlinx.serialization.Contextual
|
||||
import kotlinx.serialization.Serializable
|
||||
import java.util.UUID
|
||||
|
||||
@Serializable
|
||||
@Entity(tableName = "Theme")
|
||||
data class ColorsEntity(
|
||||
@PrimaryKey val id: UUID,
|
||||
@Serializable(with = UUIDSerializer::class) @PrimaryKey val id: UUID,
|
||||
val name: String,
|
||||
|
||||
val corePaletteA1: Int?,
|
||||
|
||||
@@ -2,11 +2,14 @@ package de.mm20.launcher2.database.entities
|
||||
|
||||
import androidx.room.Entity
|
||||
import androidx.room.PrimaryKey
|
||||
import de.mm20.launcher2.serialization.UUIDSerializer
|
||||
import kotlinx.serialization.Serializable
|
||||
import java.util.UUID
|
||||
|
||||
@Serializable
|
||||
@Entity(tableName = "Shapes")
|
||||
data class ShapesEntity(
|
||||
@PrimaryKey val id: UUID,
|
||||
@Serializable(with = UUIDSerializer::class) @PrimaryKey val id: UUID,
|
||||
val name: String,
|
||||
|
||||
val baseShape: String,
|
||||
|
||||
+4
-1
@@ -2,11 +2,14 @@ package de.mm20.launcher2.database.entities
|
||||
|
||||
import androidx.room.Entity
|
||||
import androidx.room.PrimaryKey
|
||||
import de.mm20.launcher2.serialization.UUIDSerializer
|
||||
import kotlinx.serialization.Serializable
|
||||
import java.util.UUID
|
||||
|
||||
@Serializable
|
||||
@Entity(tableName = "Transparencies")
|
||||
data class TransparenciesEntity(
|
||||
@PrimaryKey val id: UUID,
|
||||
@Serializable(with = UUIDSerializer::class) @PrimaryKey val id: UUID,
|
||||
val name: String,
|
||||
|
||||
val background: Float?,
|
||||
|
||||
@@ -2,11 +2,14 @@ package de.mm20.launcher2.database.entities
|
||||
|
||||
import androidx.room.Entity
|
||||
import androidx.room.PrimaryKey
|
||||
import de.mm20.launcher2.serialization.UUIDSerializer
|
||||
import kotlinx.serialization.Serializable
|
||||
import java.util.UUID
|
||||
|
||||
@Serializable
|
||||
@Entity(tableName = "Typography")
|
||||
data class TypographyEntity(
|
||||
@PrimaryKey val id: UUID,
|
||||
@Serializable(with = UUIDSerializer::class) @PrimaryKey val id: UUID,
|
||||
val name: String,
|
||||
|
||||
val fonts: String? = null,
|
||||
|
||||
Reference in New Issue
Block a user