mirror of
https://gitlab.bixilon.de/bixilon/minosoft.git
synced 2025-09-11 00:23:42 -04:00
cleanup VersionListCell
This commit is contained in:
parent
37c844cf8f
commit
beedfb1cf1
@ -216,7 +216,6 @@ class ServerModifyDialog(
|
||||
private val SERVER_ADDRESS_LABEL = "minosoft:modify_server.address.label".toResourceLocation()
|
||||
private val SERVER_ADDRESS_PLACEHOLDER = "minosoft:modify_server.address.placeholder".toResourceLocation()
|
||||
private val FORCED_VERSION_LABEL = "minosoft:modify_server.forced_version.label".toResourceLocation()
|
||||
val VERSION_AUTOMATIC = "minosoft:modify_server.forced_version.automatic".toResourceLocation()
|
||||
private val SHOW_RELEASES = "minosoft:modify_server.forced_version.releases".toResourceLocation()
|
||||
private val SHOW_SNAPSHOTS = "minosoft:modify_server.forced_version.snapshots".toResourceLocation()
|
||||
private val PROFILES_LABEL = "minosoft:modify_server.profiles.label".toResourceLocation()
|
||||
|
@ -14,14 +14,19 @@
|
||||
package de.bixilon.minosoft.gui.eros.util.cell
|
||||
|
||||
import de.bixilon.minosoft.Minosoft
|
||||
import de.bixilon.minosoft.gui.eros.dialog.ServerModifyDialog
|
||||
import de.bixilon.minosoft.data.registries.identified.Namespaces.i18n
|
||||
import de.bixilon.minosoft.protocol.versions.Version
|
||||
import de.bixilon.minosoft.protocol.versions.Versions
|
||||
|
||||
class VersionListCell : LabeledListCell<Version>({
|
||||
if (it == Versions.AUTOMATIC) {
|
||||
Minosoft.LANGUAGE_MANAGER.forceTranslate(ServerModifyDialog.VERSION_AUTOMATIC).message
|
||||
Minosoft.LANGUAGE_MANAGER.forceTranslate(AUTOMATIC)
|
||||
} else {
|
||||
"${it.name} (${it.type.name.lowercase()})"
|
||||
}
|
||||
})
|
||||
}) {
|
||||
|
||||
companion object {
|
||||
val AUTOMATIC = i18n("modify_server.forced_version.automatic")
|
||||
}
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user