アプリ開発備忘録

PlayStationMobile、Android、UWPの開発備忘録

Jetpack Compose Desktop 0.3->0.4のマイグレーション

自分の観測したものだけですが、記述します。

バージョン

from: 0.3.0-build152
to: 0.4.0-build168

build.gradle.kts

0.3.0

compose.desktop {
    application {
        mainClass = "MainKt"
        nativeDistributions {
            targetFormats(TargetFormat.Dmg, TargetFormat.Msi, TargetFormat.Deb)
            packageName = "review_requested"
        }
    }
}

0.4.0

OS特有の記述ができるようになったようです。

compose.desktop {
    application {
        mainClass = "MainKt"
        nativeDistributions {
            macOS {

            }

            linux {

            }

            windows {

            }

            packageName = "name"
        }
    }
}

Clickable

androidx.compose.foundation.InteractionState が無くなりました。

0.3.0

Modifier
    .clickable(
        interactionState = remember { InteractionState() },
        indication = null
    ) { }

0.4.0

Modifier
    .clickable(
        interactionSource = remember { MutableInteractionSource() },
        indication = null
    ) { }