Initial support for compose multiplatform
Signed-off-by: Aayush Gupta <aayushgupta219@gmail.com>
This commit is contained in:
parent
ef85e567fb
commit
cc74ac8ce8
27 changed files with 991 additions and 2 deletions
32
desktopApp/build.gradle.kts
Normal file
32
desktopApp/build.gradle.kts
Normal file
|
|
@ -0,0 +1,32 @@
|
|||
/*
|
||||
* SPDX-FileCopyrightText: 2026 NewPipe e.V. <https://newpipe-ev.de>
|
||||
* SPDX-License-Identifier: GPL-3.0-or-later
|
||||
*/
|
||||
|
||||
import org.jetbrains.compose.desktop.application.dsl.TargetFormat
|
||||
|
||||
plugins {
|
||||
alias(libs.plugins.jetbrains.kotlin.jvm)
|
||||
alias(libs.plugins.jetbrains.kotlin.compose)
|
||||
alias(libs.plugins.jetbrains.compose.multiplatform)
|
||||
}
|
||||
|
||||
dependencies {
|
||||
implementation(projects.shared)
|
||||
|
||||
implementation(compose.desktop.currentOs)
|
||||
implementation(libs.jetbrains.coroutines.swing)
|
||||
implementation(libs.jetbrains.compose.preview)
|
||||
}
|
||||
|
||||
compose.desktop {
|
||||
application {
|
||||
mainClass = "net.newpipe.app.MainKt"
|
||||
|
||||
nativeDistributions {
|
||||
targetFormats(TargetFormat.Dmg, TargetFormat.Msi, TargetFormat.Deb)
|
||||
packageName = "net.newpipe.app"
|
||||
packageVersion = "1.0.0"
|
||||
}
|
||||
}
|
||||
}
|
||||
18
desktopApp/src/main/kotlin/net/newpipe/app/Main.kt
Normal file
18
desktopApp/src/main/kotlin/net/newpipe/app/Main.kt
Normal file
|
|
@ -0,0 +1,18 @@
|
|||
/*
|
||||
* SPDX-FileCopyrightText: 2026 NewPipe e.V. <https://newpipe-ev.de>
|
||||
* SPDX-License-Identifier: GPL-3.0-or-later
|
||||
*/
|
||||
|
||||
package net.newpipe.app
|
||||
|
||||
import androidx.compose.ui.window.Window
|
||||
import androidx.compose.ui.window.application
|
||||
|
||||
/**
|
||||
* Entry point for compose-related UI components on Desktop
|
||||
*/
|
||||
fun main() = application {
|
||||
Window(onCloseRequest = ::exitApplication, title = "NewPipe") {
|
||||
App()
|
||||
}
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue