-
-
Notifications
You must be signed in to change notification settings - Fork 590
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: the languages menu now displays the name in the target language…
- Loading branch information
Showing
2 changed files
with
27 additions
and
5 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -9,7 +9,18 @@ package com.almasb.fxgl.localization | |
/** | ||
* @author Almas Baimagambetov ([email protected]) | ||
*/ | ||
class Language(name: String) { | ||
class Language | ||
@JvmOverloads constructor( | ||
|
||
/** | ||
* In English. | ||
*/ | ||
name: String, | ||
|
||
/** | ||
* In the target language. | ||
*/ | ||
val nativeName: String = name) { | ||
|
||
val name = name.uppercase() | ||
|
||
|
@@ -30,12 +41,12 @@ class Language(name: String) { | |
@JvmField val ESTONIAN = Language("ESTONIAN") | ||
@JvmField val FILIPINO = Language("FILIPINO") | ||
@JvmField val FINNISH = Language("FINNISH") | ||
@JvmField val FRENCH = Language("FRENCH") | ||
@JvmField val GERMAN = Language("GERMAN") | ||
@JvmField val FRENCH = Language("FRENCH", "Français") | ||
@JvmField val GERMAN = Language("GERMAN", "Deutsch") | ||
@JvmField val GREEK = Language("GREEK") | ||
@JvmField val HEBREW = Language("HEBREW") | ||
@JvmField val HINDI = Language("HINDI") | ||
@JvmField val HUNGARIAN = Language("HUNGARIAN") | ||
@JvmField val HUNGARIAN = Language("HUNGARIAN", "Magyar") | ||
@JvmField val INDONESIAN = Language("INDONESIAN") | ||
@JvmField val ITALIAN = Language("ITALIAN") | ||
@JvmField val JAPANESE = Language("JAPANESE") | ||
|
@@ -44,7 +55,7 @@ class Language(name: String) { | |
@JvmField val NORWEGIAN = Language("NORWEGIAN") | ||
@JvmField val PORTUGUESE = Language("PORTUGUESE") | ||
@JvmField val ROMANIAN = Language("ROMANIAN") | ||
@JvmField val RUSSIAN = Language("RUSSIAN") | ||
@JvmField val RUSSIAN = Language("RUSSIAN", "Русский") | ||
@JvmField val SLOVAK = Language("SLOVAK") | ||
@JvmField val SPANISH = Language("SPANISH") | ||
@JvmField val SWEDISH = Language("SWEDISH") | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters