41 lines
958 B
Kotlin
41 lines
958 B
Kotlin
package org.hso.texturesyncclient.view.mainView
|
|
|
|
import javafx.collections.ListChangeListener
|
|
import javafx.scene.image.Image
|
|
import tornadofx.*
|
|
|
|
class MainView : View() {
|
|
|
|
val folderView = find(FolderView::class)
|
|
val detailView = find(DetailView::class)
|
|
|
|
private val mvc: MainViewController by inject()
|
|
|
|
override val root = borderpane {
|
|
minWidth = 1000.0
|
|
minHeight = 500.0
|
|
|
|
left = folderView.root
|
|
right = detailView.root
|
|
|
|
style {
|
|
// style options
|
|
}
|
|
|
|
// actions
|
|
// folderView.btn1.setOnAction {
|
|
// mvc.setPreview3DTexture(Image("textures/sample_texture_1.jpg"))
|
|
// mvc.setMeta("texture 1", "8MP", "Quelle: wikipedia")
|
|
// mvc.setTags(observableList("Stein", "Rot", "super"))
|
|
// }
|
|
|
|
detailView.cvTags.chips.addListener { change: ListChangeListener.Change<out String>? ->
|
|
mvc.updateTags()
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
} |