Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Make stable for balloon builder and factory #575

Merged
merged 2 commits into from
Jan 5, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions balloon/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -91,5 +91,7 @@ dependencies {
implementation(libs.androidx.lifecycle)
implementation(libs.androidx.annotation)

compileOnly(libs.compose.stable.marker)

baselineProfile(project(":benchmark"))
}
3 changes: 3 additions & 0 deletions balloon/src/main/kotlin/com/skydoves/balloon/Balloon.kt
Original file line number Diff line number Diff line change
Expand Up @@ -63,6 +63,7 @@ import androidx.annotation.MainThread
import androidx.annotation.Px
import androidx.annotation.StringRes
import androidx.annotation.StyleRes
import androidx.compose.runtime.Stable
import androidx.core.view.ViewCompat
import androidx.core.view.forEach
import androidx.core.view.get
Expand Down Expand Up @@ -1900,6 +1901,7 @@ public class Balloon private constructor(
}

/** Builder class for creating [Balloon]. */
@Stable
@BalloonInlineDsl
public class Builder(private val context: Context) {
@Px
Expand Down Expand Up @@ -3159,6 +3161,7 @@ public class Balloon private constructor(
*
* @see [Lazy Initialization](https://github.com/skydoves/Balloon#lazy-initialization)
*/
@Stable
public abstract class Factory {

/**
Expand Down
2 changes: 2 additions & 0 deletions gradle/libs.versions.toml
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ androidxLifecycle = "2.6.2"
androidxAnnotation = "1.7.1"
androidxMacroBenchmark = "1.2.2"
androidxTest = "1.5.2"
composeStableMarker = "1.0.2"
baselineProfiles = "1.3.1"
uiAutomator = "2.3.0-beta01"
spotless = "6.21.0"
Expand Down Expand Up @@ -47,6 +48,7 @@ androidx-activity-compose = { group = "androidx.activity", name = "activity-comp
androidx-compose-foundation = { group = "androidx.compose.foundation", name = "foundation" }
androidx-compose-runtime = { group = "androidx.compose.runtime", name = "runtime" }
androidx-compose-constraintlayout = { group = "androidx.constraintlayout", name = "constraintlayout-compose", version.ref = "androidxComposeConstraintLayout" }
compose-stable-marker = { group = "com.github.skydoves", name = "compose-stable-marker", version.ref = "composeStableMarker" }

# unit test
androidx-test-runner = { group = "androidx.test", name = "runner", version.ref = "androidxTest" }
Expand Down