diff options
| author | 2023-03-07 17:19:36 -0500 | |
|---|---|---|
| committer | 2023-06-03 00:05:36 -0700 | |
| commit | 2439fc8374ae7689a6535476f0574452cd0a218b (patch) | |
| tree | 25e35115d64ae87d47f2624d692969c38c3b73b6 /src | |
| parent | android: Convert BooleanSetting to Kotlin (diff) | |
| download | yuzu-2439fc8374ae7689a6535476f0574452cd0a218b.tar.gz yuzu-2439fc8374ae7689a6535476f0574452cd0a218b.tar.xz yuzu-2439fc8374ae7689a6535476f0574452cd0a218b.zip | |
android: Convert FloatSetting to Kotlin
Diffstat (limited to 'src')
2 files changed, 9 insertions, 23 deletions
diff --git a/src/android/app/src/main/java/org/yuzu/yuzu_emu/features/settings/model/FloatSetting.java b/src/android/app/src/main/java/org/yuzu/yuzu_emu/features/settings/model/FloatSetting.java deleted file mode 100644 index 9b9b60092..000000000 --- a/src/android/app/src/main/java/org/yuzu/yuzu_emu/features/settings/model/FloatSetting.java +++ /dev/null | |||
| @@ -1,23 +0,0 @@ | |||
| 1 | package org.yuzu.yuzu_emu.features.settings.model; | ||
| 2 | |||
| 3 | public final class FloatSetting extends Setting { | ||
| 4 | private float mValue; | ||
| 5 | |||
| 6 | public FloatSetting(String key, String section, float value) { | ||
| 7 | super(key, section); | ||
| 8 | mValue = value; | ||
| 9 | } | ||
| 10 | |||
| 11 | public float getValue() { | ||
| 12 | return mValue; | ||
| 13 | } | ||
| 14 | |||
| 15 | public void setValue(float value) { | ||
| 16 | mValue = value; | ||
| 17 | } | ||
| 18 | |||
| 19 | @Override | ||
| 20 | public String getValueAsString() { | ||
| 21 | return Float.toString(mValue); | ||
| 22 | } | ||
| 23 | } | ||
diff --git a/src/android/app/src/main/java/org/yuzu/yuzu_emu/features/settings/model/FloatSetting.kt b/src/android/app/src/main/java/org/yuzu/yuzu_emu/features/settings/model/FloatSetting.kt new file mode 100644 index 000000000..f0a4a3637 --- /dev/null +++ b/src/android/app/src/main/java/org/yuzu/yuzu_emu/features/settings/model/FloatSetting.kt | |||
| @@ -0,0 +1,9 @@ | |||
| 1 | package org.yuzu.yuzu_emu.features.settings.model | ||
| 2 | |||
| 3 | class FloatSetting( | ||
| 4 | key: String, | ||
| 5 | section: String, | ||
| 6 | var value: Float | ||
| 7 | ) : Setting(key, section) { | ||
| 8 | override val valueAsString = value.toString() | ||
| 9 | } | ||